Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Hot keys for buttons
Message
Information générale
Forum:
Visual FoxPro
Catégorie:
Gestionnaire d'écran & Écrans
Divers
Thread ID:
00665597
Message ID:
00665598
Vues:
20
Set the cancel prop to .T.



>Hi everybody,
>
>How can I find out, if button has a Hot Key (letter highlighted) and what's the value of it. Say, I have Cancel button with first letter highlighted. I added in my CancelValidation method of the form:
>
>
>********************************************************************
>*  Description.......: CancelValidation
>*  Calling Samples...:
>*  Parameter List....:
>*  Created by........: John Koziol
>*  Modified by.......:
>********************************************************************
>local nCancelTop,nCancelHeight,nCancelLeft,nCancelWidth, llReturn
>nCancelTop=thisform.cmdCancel.top
>nCancelBottom=m.nCancelTop+thisform.cmdCancel.height
>nCancelLeft=thisform.cmdCancel.left
>nCancelRight=m.nCancelLeft+thisform.cmdCancel.width
>llReturn = .f.
>if between(mrow(thisform.name,3),m.nCancelTop,m.nCancelBottom) and ;
>		between(mcol(thisform.name,3),m.nCancelLeft,m.nCancelRight) and ;
>		mdown()
>	llReturn = .t.
>endif
>return m.llReturn or lastkey()= 46 && Alt+C (shortcut for Cancel)
>
>Is there a way to make this more generic (e.g. find out key combination for Cancel button automatically)?
If we exchange an apple, we both get an apple.
But if we exchange an idea, we both get 2 ideas, cool...


Gérald Santerre
Independant programmer - internet or intranet stuff - always looking for contracts big or small :)
http://www.siteintranet.qc.ca
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform