Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Problem with the Grid
Message
 
À
04/02/2003 12:36:34
Information générale
Forum:
Visual FoxPro
Catégorie:
Gestionnaire d'écran & Écrans
Divers
Thread ID:
00748941
Message ID:
00749133
Vues:
27
>i am using the following statment for gird control
>SELECT medicine,QTY,MRP,RACKNO,BATCHNO,EXPDATE FROM STOCK INTO CURSOR Custs and now i want to set focus to other grid in the form when the user press the enter how will i do this

Could you provide more details?
Is this SQL statement your Grid.RecordSource?
Or, do you want to execute this statement in one grid on pressing Enter and display the result in other grid?
If the focus is currently in one grid and you want to set focus to another grid, then you should do something like this:
*** Grid1.Column1.Text1.KeyPress event 
lParameter nKeyCode
IF nKeyCode = 13 && Enter
     thisform.Grid2.SetFocus()
ENDIF
You might need to place this code to every column's textbox to be able to set focus from anywhere in the first grid.
However I don't know how is the SQL statement is related to this.
Nick Neklioudov
Universal Thread Consultant
3 times Microsoft MVP - Visual FoxPro

"I have not failed. I've just found 10,000 ways that don't work." - Thomas Edison
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform