Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Setting focus if validation code returns false
Message
From
01/07/1998 16:26:01
 
 
To
01/07/1998 16:18:33
General information
Forum:
Visual FoxPro
Category:
Forms & Form designer
Miscellaneous
Thread ID:
00113554
Message ID:
00113562
Views:
24
>I have a lookup that returns .t. or .f. is a customer is found. If my code is in the valid method I get the "invalid input" message which I don't want. I have put the code in the lostfocus method to avoid this, but I cannot setfocus to the textbox if my lookup returns .f.. Any ideas ???? In FPW 2.6 I would put my lookup code in the valid and return .t. regardless of the outcome and use _CUROBJ = OBJUNUM() and then SHOW GET ENABLE and everything worked just fine. I looked at SBT Accounting Software code and they have an elaborate way of calling the gotfocus method from the lostfocus method and a hundred other functions to do this, but I don't think I have to spend a day writing functions to simply reset focus to the current object. Isn't there a simple way to do this ??????
>
>Thanks in advance !!!!!!

Use SET NOTIFY OFF to suppress unwanted 'valid' messages. Use NODEFAULT if you want to apply SetFocus() in Lostfocus event.
Edward Pikman
Independent Consultant
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform