Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Can't focus on my form
Message
Information générale
Forum:
Visual FoxPro
Catégorie:
Gestionnaire d'écran & Écrans
Divers
Thread ID:
00330607
Message ID:
00330802
Vues:
11
>>If what Bruce has suggested doesn't work for you, try setting the focus to your control in the form's GotFocus, not the Init. Strange things happen if you try to SetFocus from the Init.
>
>Indeed, you've disturbed the natural event firing, though depending on what you're doing, it may not cause trouble...probably a good thing to avoid, in general, though. A setfocus in the Init causes the form Activate (and anything it runs) to run earlier than normal, then the Init finishes up...

That's pretty much what I discovered (the hard way, of course!). At least until I found out about LISAG, anyways. I usually don't have problems with a SetFocus in the Activate or the GotFocus, but it took quite awhile to track down a problem on some machines when a SetFocus was called by some code in an Init.
Fred
Microsoft Visual FoxPro MVP

foxcentral.net
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform