Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Problem with SetFocus method!
Message
Information générale
Forum:
Visual FoxPro
Catégorie:
Codage, syntaxe et commandes
Titre:
Problem with SetFocus method!
Divers
Thread ID:
00011060
Message ID:
00011060
Vues:
87
I have a form with two textboxes (Text1 & Text2) and two commandbuttons (Command1 & Command2). Set the tab order to the following: Command1, Text1, Command2, Text2. Set the enabled property for Text2 and Command2 to .F.. I have the following code in the Click event of Command1:
THISFORM.Text2.Enabled = .T.
THISFORM.Text1.Enabled = .F.
THISFORM.Command2.Enabled = .T.
THISFORM.Command1.Enabled = .F.
THISFORM.Text2.SetFocus()

When I run this form and press the Command1 button the focus jumps to the command2 button. However, when I step through the code in the trace window it seems to work ok.

Any ideas?
Shane Murdoch
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform