Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Get Controls Hierarchy at design time.
Message
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Miscellaneous
Thread ID:
00565636
Message ID:
00565660
Views:
14
>>>Is there a way to get a controls hierarchy at design time? I see the SYS(1272) but it's only good at runtime. I can select a group of controls and get there names with ASELOBJ but I'm not sure how to get the hierarchy ie. form name, pageframe..... TIA
>>
>>From parent to childs you can do something like this !
>>
>>For m.i = 1 TO thisform.ControlCount
>>    oControl = thisform.Controls[m.i]
>>    If  oControl.Baseclass$"Pageframe Container "
>>        For m.j = 1 TO oControl.controlCount
>>            oCHILDControl = oControl.controls[m.j]
>>            wait window "Here is the name of the control:"+oCHILDControl.name nowait
>>        endfor
>>    endif
>>endfor
>>
>>
>>
>>Ps: Say hello to people of BR (I used to live there for more than one year ! Great city, nice people !)
>>
>>
>>CLAUDIO
>
>Looks good, I'll give it a try. Thanks Claudio

Doesn't look like that is quite what I need. I'm looking for something that will work in design mode not at runtime. Can't use thisform.ControlCount from the command window. I'm trying to select a group of controls on a form and have a routine build me a list of these controls prefixed with there location. ie: form1.pageframe1.textbox . I can create a list of the controls with ASELOBJ and looping through it. Just not sure how to get the hierarchy in. Thanks again....
Previous
Reply
Map
View

Click here to load this message in the networking platform