Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
When event fires at different times !!!
Message
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Miscellaneous
Thread ID:
00757449
Message ID:
00757503
Views:
12
Gerard,

If you think about it the event sequence makes perfect sense. When you click on the button its Click event fires as that is the event that will try to put focus on the button. Because the click event tries to put focus on the button the When event fires. If you tab to the button it is the key stroke of Tab that tries to put focus on thebutton and it causes the When event to fire. If the button already has focus (you tanned to it) and you click on it, the click event does NOT try to put focus on the button because focus is already on the button so in this case the When does not fire.

Perhaps you are trying to use the When event for something that it is not suited to do. The When's purpose in life is to decide whether or not focus will be allowed on the control retunr .T, to allow it and .F. to disallow it. Using the when for anything else can be tricky.
Previous
Reply
Map
View

Click here to load this message in the networking platform