Information générale
Catégorie:
Codage, syntaxe et commandes
>>FoxPro's DEFAULT KeyPress code needs to receive the parameters just like the code above does. Replace DODEFAULT() with DODEFAULT(nKeyCode, nShiftAltCtrl) and give it another try.
>
>Thanks for the idea Bob, however I still have the same strange behavior... fields getting skipped on Tab and the "Property Value not found" error.
If you haven't seen this before, at least I can confirm that it's not supposed to happen. Must be some more general thing is going on. Actually, without the parameters being passed, you should have had other problems so I suspect that your code IS NOT being run ... something else is.
Check the root level of the form for the KeyPreview property. It must be set to .t. for your form level KeyPress code to work. Otherwise, the KeyPress code attached to each control is what gets used. In my system these are all empty. The KeyPreview property is used to allow the form to handle KeyPress events before the active control processes them.
Bob
Précédent
Suivant
Répondre
Voir le fil de ce thread
Voir le fil de ce thread à partir de ce message seulement
Voir tous les messages de ce thread
Voir tous les messages de ce thread à partir de ce message seulement