Hi Theo, thank you for your contribution, its very good to have some additional views on that issue. My wish was sparked because a HTML file I created from sourcecode, did not work any more in the HTML widget of 9.6 from one day to the other. Someone used the same tag-id in a #for loop, but had not #undefine'd it after the #endfor. So instead of the tag the file included the value of the constant and the display was neatly messed up. "There is a possibility for a theoretical conflict, but since your defines and your blockdata are in the same Uniface component, it would be a little bit strange if you ran into a conflict with yourself." In my post above I mentioned GLOBAL constants which are not in the scope of the component. Same goes if some other programmer added something in the defines triggers (or uses a #for #endfor without #undefine). And do not forget all the things which are done already with #include procs which are not visible in the source text any more. The ones changing the include procs have no means to check any single code their code is included for sideeffects. On your %% suggestion: unfortunately %%s are not processed within blockdata and I use sometimes the combination of %%..%%% together with precompiler constants already in my coding to include the external version of fields in a string driven by a #for loop. Agreed, the #noprecompiler / #endnoprecompiler is not too elegant and we may have errors of "unbalanced ..." But if you copy some HTML file into blockdata to use it as a template, you need some instrument of protection. As it looks, this may be the "minimal inversive" implementation of that functionality. On the gold family: I think about something like GOLD{ and GOLD} as a begin-tag/end-tag replacement. Perhaps we can add another option which is converted to a "non-commenting-;" so we can #define a text including a ";" This way, we can have tags and constants mixed in a single command (expl. replace a constant with a tag in the output file). Because these combinations are brand-new, there should not be too many side-effects (beside some KTLs). Perhaps we need some enable/disable options for the ASN file to guard them. So it would be beneficial to see the enhanced GOLD-family and the #noprecompiler / #endnoprecompiler implemented.
Author: ulrich-merkel (
ulrichmerkel@web.de)