Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
SetFocus won't work in Valid?
Message
From
06/04/1999 12:42:56
 
 
To
06/04/1999 03:36:36
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Miscellaneous
Thread ID:
00205503
Message ID:
00205626
Views:
17
Gan,

At least in Hacker's Guide, it specifically states that SetFocus can't be called from the Valid or When methods. SetFocus should be called from GotFocus, LostFocus.

To control focus from Valids, you need to use Return 0, Return .F.

PF


>I need to SetFocus back to the textbox after it losses it focus when it's empty. I try setting enable = .F. for all other controls but it's not very good idea for my task. However the SetFocus won't work in Valid, compared to Init.
>
>Thanks in advance.
>
>Gan

(On an infant's shirt): Already smarter than Bush
Previous
Reply
Map
View

Click here to load this message in the networking platform