Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Knowing which of 2 grids has the focus?
Message
 
 
Information générale
Forum:
Visual FoxPro
Catégorie:
Programmation Orientée Object
Divers
Thread ID:
00577418
Message ID:
00577429
Vues:
22
I didn't notice, you don't use buttons. How do you process F3, in Form's KeyPress? This technique is still valid, but you probably don't need an additional form's property. Just check thisform.ActiveControl in KeyPress method of the form.

>>Hi All,
>>
>>I have a form with 2 grids on it. Each has a cursor attached to it. There could be from 0 – N records in each cursor. When the user hits ‘F3’ I want to add a blank record to 1 of the cursors.
>>
>>Without asking the user which grid should get the new record. How can I tell where they want to add the new record? 1 of the grids is to be the default grid. But how can I tell when the user wants to enter data into the other? Or wants to switch back?
>>
>>1 of the grids uses a floating container for data entry. (The default grid) The other is direct entry into the grid.
>>
>>TIA
>>Mike
>
>You probably can tell by thisform.ActiveControl
>
>In other words, add a new property to a form oLastActive. Store to it thisform.ActiveControl in Command.button When event. Don't forget to set this property to null in Form's Destroy.
If it's not broken, fix it until it is.


My Blog
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform