Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Has any one know the event firing Command button
Message
From
28/09/1997 22:33:06
Frank Shaw
Runestones Development Corporation
Ipswich, Massachusetts, United States
 
 
To
All
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Title:
Has any one know the event firing Command button
Miscellaneous
Thread ID:
00052099
Message ID:
00052099
Views:
83
I have a command button on the screen and a number of fields. I have code that happens in the lost focus event of a control on the form. In the click event of the command button I want to set a flag then logic says that I can In the lost focus event of the control I can test the flag. But the lost focus event fires before the click event so this will not work. I need a way to tell me that I have press with the mouse down on the command button so that I can test for a status, I set the debugger to trace the following from the READ EVENTS which starts the event loop processing I see that gotfocus event of the continer contained in the form fires then the gotfocus event of the control fires. Back to the READ EVENT Then I click on the command button but the click event does not fire at this point but the lostfocus event of the control does fire which at this point back to the
READ EVENT I have to press on the Command button again this time the click event does fire and the rest of the code calls what it should, But it is to late to set the flag because the lostfocus of the control fired last time. I need a way to tell the application that I pressed the command button the first time when I press on it so I can set a flag. Any Ideas about how to do this One note: I set a break point in the debugger in the Gotfocus event of the container and their I was able to see that might be able to do some thing like controls(I) but what would I look for to tell If the command button was pressed before the lostfocus event of the control.

fshaw@runestones.com
Next
Reply
Map
View

Click here to load this message in the networking platform