Welcome Serena Central users! CLICK HERE
The migration of the Serena Central community is currently underway. Be sure to read THIS MESSAGE to get your new login set up to access your account.
RobertRedekop Trusted Contributor.
Trusted Contributor.

How can I loop through all the controls in a screen section?

We have a function/screen which uses the screen section to do it's work.  It's older, and needs to be made larger.   I was thinking i would prefer to make it automatically resize so I looked at the layout manager option in the manual, but apparently that can only resize the control, not the fonts in labels and/or entry fields.  So now I'm thinking okay, lets just loop through all the controls in the screen section, doing the "adjustment" that the layout manager would have done.  And use W$FONT to resize the fonts - changing the font sizes when there's enough room.  (Yes, I know I'll have to handle changing the font handle in those controls that need a new font - I think I have a plan for that).  The basic thing I don't know how to do is set up a loop that goes through all the controls in a screen section.


Plan B would be to set up an evaluate that maps loop indexes to controls, and use SET HANDLE to save the handle for all the controls.

The opinions expressed above are the personal opinions of the authors, not of Micro Focus. By using this site, you accept the Terms of Use and Rules of Participation. Certain versions of content ("Material") accessible here may contain branding from Hewlett-Packard Company (now HP Inc.) and Hewlett Packard Enterprise Company. As of September 1, 2017, the Material is now offered by Micro Focus, a separately owned and operated company. Any reference to the HP and Hewlett Packard Enterprise/HPE marks is historical in nature, and the HP and Hewlett Packard Enterprise/HPE marks are the property of their respective owners.