Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Event Sequencing
Message
General information
Forum:
Visual FoxPro
Category:
Object Oriented Programming
Miscellaneous
Thread ID:
00468044
Message ID:
00468125
Views:
19
>>>Is there any way to control the sequencing of events on a form? For instance, lets say that I have to go in and modify a form and add an object to support some new data. I need it to refresh at a certain point, but because it was added late, it doesn't refresh when I desire.
>>>
>>>Does this make sense?
>>>
>>>Grace and peace,
>>>
>>>John
>>
>>I *think* I've heard that resetting the tab order of controls forces the controls to be written out in that order during a save of the form. I've not tested this myself, so I'm not sure.
>>
>>You could be setting yourself up for some future problems with this kind of dependency, though.
>
>No, it is not the Tab order, but Bring To Front/Send To Back changes the order of instantiation.

I knew it was something you could do, short of deleting all the controls and re-adding them in the order you wanted. Thanks for the clarification, Nick.

>
>Say, you placed 7 textboxes on the form.
>
>If you select Text3 and send it to back, next time the form is run it will be instantiated first. If you use for it Bring To Front button next time Text3.Init will fire the last (just before Form.Init()). You can see it if you turn on Event Tracking for INIT()
>
>You are right, it is not very reliable method of controlling the event sequence, as the ZOrder can be easily changed by mistake and if the controls are not overlapping you may never notice it.

No joke. We do use it for one thing. We have a TreeView and a ImageList in a container. Our baseclass TreeView has some code it's init to set the .ImageList property to the ImageList object, so the ImageList object has to instanciate first.
Fred
Microsoft Visual FoxPro MVP

foxcentral.net
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform