Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
How to SetFocus() from Valid()?
Message
De
10/06/2002 15:07:04
Irv Adams
MSC Managed Care, Inc.
Floride, États-Unis
 
 
À
10/06/2002 14:58:36
Charlie Hancock
California Dept of Public Health
Richmond, Californie, États-Unis
Information générale
Forum:
Visual FoxPro
Catégorie:
Gestionnaire d'écran & Écrans
Divers
Thread ID:
00666645
Message ID:
00666655
Vues:
20
Charlie:

This should work OK, make certain you do the DoDefault() command in the Lostfocus first prior to calling the Form...

HTH,

-Irv.


>My application has two forms visible: one, in the foreground, is a data entry form, the other, in the background, displays a grid of possible duplicate records. The desired behavior is that the user will enter a customer's first & last name in the first form. The last name textbox's .Valid() code then calls a method in the second form that searches for and displays any existing customers with matching names. So far so good. At this point, I want to bring the second form to the top, which is where I'm having the problem.
>
>I know I can't SetFocus() to the second form's grid (or to anyplace else)from the first form's textbox Valid() event. The documentation suggests using .LostFocus() as a place to do that. But when I try, the second form's grid momentarily gets the focus, then focus jumps right back to the first form (in the data entry textbox following the last name textbox). The same occurs when I call the second form's .Show() event. Any ideas on how to keep focus on the second form once it gets there?
>
>Thanks in advance!
>
>Charlie Hancock
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform