Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Focus not moving off button
Message
De
11/12/2007 14:16:20
 
 
Information générale
Forum:
Visual FoxPro
Catégorie:
Gestionnaire d'écran & Écrans
Versions des environnements
Visual FoxPro:
VFP 9 SP1
OS:
Windows 2000 SP4
Network:
Windows 2000 Server
Database:
MS SQL Server
Divers
Thread ID:
01274885
Message ID:
01274905
Vues:
9
Hi Sergey,

Both Naomi's and your suggestions made me go back and step through my code again. I swear I stepped through it before. But this time, I found that my end code was not in the correct place, in one IF statement too far. I moved it out, put the setfocus back in instead of the keyboards, and it works. *red face*
thanks for all your and Naomi's help
Beth

>Try to add NODEFAULT.
>
>THISFORM.grid1.setfocus()
>NODEFAULT
>
>
>>
>>I have a form with a grid, lots of textboxes, and some buttons. In one button, if the main code there is not to be run because of something wrong with data, I want the focus to go back to the grid, highlighting the selected record. But nothing I do seems to move the focus off the button.
>>
>>Here is the ending code I have under the button at the moment:
>>
>>  THISFORM.setbuttons()
>>  KEYBOARD '{TAB}'
>>  KEYBOARD '{TAB}'
>>  THISFORM.REFRESH()
>>
>>
>>setbuttons() just enables and disables the buttons as needed.
>>I have tried:
>>
>>  THISFORM.setbuttons()
>>  THISFORM.grid1.setfocus()
>>  THISFORM.REFRESH()
>>
>>but that does not put the focus where I want it.
>>
>>TIA
>>Beth
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform