Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Hot keys for buttons
Message
General information
Forum:
Visual FoxPro
Category:
Forms & Form designer
Miscellaneous
Thread ID:
00665597
Message ID:
00665600
Views:
23
>Set the cancel prop to .T.

No, I don't want to. ESC usually just revert the last input...
>
>
>
>>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 it's not broken, fix it until it is.


My Blog
Previous
Reply
Map
View

Click here to load this message in the networking platform