Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Moving focus programmatically
Message
Information générale
Forum:
Visual FoxPro
Catégorie:
Gestionnaire d'écran & Écrans
Divers
Thread ID:
00918346
Message ID:
00918895
Vues:
7
Non va bene quello che avevo già scritto?
Per ogni textbox della grid inserisci (nell'evento keypress):

IF nkeycode = 9
thisform.thetextbox.SetFocus
NODEFAULT
ELSE
DODEFAULT()
ENDIF

Altrimenti non ho capito cosa intendi....

>Ok, Franco ti nomino mio salvatore personale !!!! :-))
>cmq... il codice che mi hai dato funziona, io mi ero impicciato con il keypress del form....ma come faccio per uscire dal grid con il TAB e riposizionarmi sulla casella di testo ?
>
>Ok Franco, it seems like you were my personal tutor :-))
>Anyway, te code works fine but what should I do to exit with the tab key from the grid an set the focus on the textbox ?
>
>
>>Alessio, in textbox.keypress put:
>>
>>DO CASE
>>CASE nkeycode=13
>> thisform.thegrid.SetFocus
>> nodefault
>>CASE nkeycode = 9
>> thisform.thecontainder.SetFocus
>> NODEFAULT
>>OTHERWISE
>> DODEFAULT()
>>ENDCASE
>>
>>in every textbox contained in the grid put this code in the .keypress event
>>
>>IF nkeycode = 9
>> thisform.thetextbox.SetFocus
>> NODEFAULT
>>ELSE
>> DODEFAULT()
>>ENDIF
>>
>>ciao
>>(scusa per l'inglese:))
>>
>>Faanco
>>
>>>I have a form with a textbox, a grid and a conteiner with some buttons, what i'd like to do is :
>>>
>>>a) When I am inside the textbox and press enter key i should go inside the grid
>>>
>>>b) if I am inside the grid and press the tab key i should go inside the textbox
>>>
>>>c) if I am inside the textbox and press the tabkey I should go inside the container
>>>
>>>I put the grid.allowcellselection to .T.
>>>
>>>What i get at the moment is that pressing tab inside the grid i can see the focus going to the textbox for a while then immediatelly to the container.
>>>I hope i was clear in expplaining
>>>
>>>Thanks
>>>ALessio
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform