Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Setfocus() in valid()
Message
 
 
To
12/06/1998 11:47:24
General information
Forum:
Visual FoxPro
Category:
Other
Miscellaneous
Thread ID:
00107627
Message ID:
00107640
Views:
11
>I have a valid() function for a textbox, so that if the input was "?", then a look-up form is launched to list customers in a grid. The lookup form has an OptionGroup that allows you to filter "Active" customers or "Inactive" customers, or "All" customers. In the click event, I try to pass focus back to the grid after setting the filter, so that the arrow keys can be used to scroll the grid.
>
>Since the form is a child of a calling valid() function, it will not allow the setfocus() command.
>
>What is a work-around, so that the user does not have to click the grid with the mouse in order to begind using the arrow keys again?
>
>When the form is used simply as a customer lookup table, and NOT called from a valid() function, the setfocus() is allowed.
>
>I understand how and why it works like it does, I just need to find a work around.

Try moving your textbox valid() function to the textbox click event. You will have to setfocus back to the textbox when returning .F. from the function.
Michael McLain
Previous
Reply
Map
View

Click here to load this message in the networking platform