Hello,
It's ok for me if I compile the Aditya file.
I have another problem with a simple structure. I created the file MyLayout.tex containing the macro and I want to call this macro in the dm1.tex file, but it does not work.
Thank you
Fabrice
#########
MyLayout.tex
#########
% macros=mkvi
\startenvironment MyLayout
\setuplayout
[header=3\lineheight,
headerdistance=\lineheight]
\setupbackgrounds
[header]
[text]
[
frame=off,
bottomframe=on,
framecolor=darkgray,
rulethickness=2pt,
]
\defineframed[headerframed]
[
frame=off, % For visualization set this to on
height=fit,
width=fit,
location=bottom,
boffset=\lineheight,
]
\starttexdefinition MyHeader #where #day #month #year #title #number #time
\setupheadertexts
[{\headerframed[align=middle, foregroundstyle=bold, foregroundcolor=red]
{#title n\high{o}\,#number}}]
\setupheadertexts
[{\headerframed[align=flushleft, foregroundstyle=\ssx]
{Lycée JANSON DE SAILLY \\ \date[d=#day,m=#month,y=#year]}}]
[{\headerframed[align=flushright, foregroundstyle=\ssx]
{#where \\ {#time}}}]
\stoptexdefinition
\stopenvironment
######
dm-1.tex
######
\startcomponent dm-1
\environment MyLayout
\MyHeader{Seconde}{17}{08}{2017}{Devoir surveillé}{1}{1h\,30m}
\input knuth
\stopcomponent