Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Before/After RowColChange
Message
 
To
13/08/2008 13:48:20
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Environment versions
Visual FoxPro:
VFP 8 SP1
Miscellaneous
Thread ID:
01338480
Message ID:
01338778
Views:
16
Hi Rich,

> I can see that the cmdExit button has focus but if the user now presses the SAVE button or the EXIT button, the first code that fires is the grid's BeforeRowColChange method.

Does this code fire even before the Click or the When event of the button?

In any case, if I encounter such situations I usually resolve them with a timer. Add a timer object, set the interval to 10 ms and disable it. In the Timer method call the SetFocus method of your button. In the grid enable the timer instead of setting the focus. This lets the grid finish the event sequence and then start afresh instead of moving the focus while the focus is moving from one row to the other, saving data as VFP is trying to refresh a non-active row.
--
Christof
Previous
Reply
Map
View

Click here to load this message in the networking platform