I would like to write a text file from a LaTeX document with the following format:
where A, C, D and B are to be written into the text file from different places of the LaTeX document. Thus, I cannot at once write
and so on.
Could you please help me?
Thanks in advance,