It is possible to read and update the structure of a form in Uniface proc code without
resorting to 3gl. The positions and sizes of widgets on a form are stored in the Uniface
table UFORM, in the FORMPIC field. The FORMPIC field contains embedded hex
1A characters that cannot normally be directly manipulated in Uniface proc code.
However, if the Decrypt trigger of FORMPIC is modified to include a dummy statement,
such as $1 = 0 then the FORMPIC is automatically transformed. The hex 1A characters
are replaced. And the resulting text can easily be scanned and updated. Afterwards, the
updated FORMPIC text can be stored back to UFORM, and in the process it will
automatically be translated back to its internal format (including hex 1A characters).
The form included here as a Uniface export file uses this technique to search a specified
set of forms and replace all occurrences of a label containing given text with some given
replacement text.
Apart from requiring the definition of the UFORM table (available in the umeta.trx file
provided with Uniface) this form is self contained; it does not use any global objects.
You should be able to import it into a Uniface environment, compile it and then run it
immediately.
Notes
This form was developed and tested under Uniface 7.2.04 on Windows NT.
It uses an undocumented feature of Uniface, and as such you use it at your own risk.
There is no guarantee that it will work in future versions of Uniface, or even that it will
work reliably under Uniface 7.2.04.