|Home » Technical Support » Elevate Web Builder Technical Support » Support Forums » Elevate Web Builder General » View Thread|
|Messages 1 to 3 of 3 total|
|Form controls and recursive coding|
|Sun, Jul 8 2018 8:05 AM||Permanent Link|
Does anybody have a good recursive method for going through all controls on a form and setting their caption. I am especially thinking about cases where you have a panel within a panel within a panel, etc. and each with its own embedded controls.
|Sun, Jul 8 2018 10:52 AM||Permanent Link|
> Does anybody have a good recursive method for going through all controls
> on a form and setting their caption. I am especially thinking about cases
> where you have a panel within a panel within a panel, etc. and each with
> its own embedded controls.
Not hard to do your own. Just recurse on the too. And you can pass a
callback if that is a better option than coding in-situ.
I can dig something up later as an example.
|Mon, Jul 9 2018 4:33 AM||Permanent Link|
procedure UpdatePanelTags(xPanel : TBasicPanel);
nTag : Integer;
nTag := xPanel.Tag;
for i := xPanel.componentcount - 1 downto 0 do
c := xPanel.component[i];
c.Tag := nTag;
if c is TBasicPanel then
Expand as appropriate...