Am 21.01.2009 um 19:28 schrieb Cecil Westerhof:
2009/1/21 Wolfgang Schuster
: When the first parameter is filled, but not with a recognized value, then the second parameter should be filled. If not, the compilation of the file should generate an error.
I did only what you wrote.
I was not clear enough again. What I mend was that when there is not a recognized value, then the output file should not be generated. When you give a return the file is still generated. But that is only a minor. (Maybe what I want is not possible.)
\long\def\letterbody#1% {\def\@@letterbody{{\blank[line]\setupindenting[yes,medium]#1\par}}} \def\letterclosing {\dodoublegroupempty\doletterclosing} \def\doletterclosing#1#2% {\ifsecondargument \dodoletterclosing{#1}{#2}% \else \doifelsenothing{#1} {\dodoletterclosing{Hoogachtend,}{Cecil Westerhof}}% {\processaction [#1] [ family=>{\dodoletterclosing{Informal closing,}{Cecil Westerhof}}, business=>{\dodoletterclosing{Formal closing}{Cecil Westerhof}}, unknown=>{\message{Warning: Wrong keyword for \string \letterclosing.}}]}% \fi} \def\dodoletterclosing#1#2% {\@@letterbody \blank[line]#1\blank[3*line]#2} \starttext \letterbody{\dorecurse{2}{\input knuth\par}} \letterclosing{unknown} \stoptext Best wishes Wolfgang