My problem is quite simple, I would like to store values in a paragraph outside the paragraph ( the values stored outside should also not be visible in the final PDF )
Something like below :
\label{name}{Harry}
\label{age}{19}
Dear \ref{Name},
I hope this letter finds you well.
Today is a very special day as it marks your \ref{age} birthday!
It is so that I can define my values in one place instead of re-editing all of them, it must be quite simple, it's just that I cannot seem to figure it out.
\def\age{19}, and then use\agein your document – samcarter_is_at_topanswers.xyz Apr 29 '23 at 11:26\newcommandto be safer – David Carlisle Apr 29 '23 at 11:33but what happens when your document and macros get large ?
are they locally or only globally defined ?
for example if at the start of the document you use \age, but you redefine it on page 300 to something else.
is there a structured way to do it ?
– sourcevault Apr 29 '23 at 11:34