Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Inkey value for X close button on top of right hand corn
Message
From
22/09/1997 13:52:37
 
 
To
22/09/1997 12:39:24
Jim Si
Alberta Research Council
Calgary, Alberta, Canada
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Miscellaneous
Thread ID:
00051043
Message ID:
00051070
Views:
37
>>
>>That's a good example why it's not healthy practice to use Control.Valid events. IMHO, the right solution is to move all validations to cmdSave.Click event.
>
>Thank you for replying.
>
>I have an initial form. There is only one sigificant object which is the combo box. According the value picked from the combo box the corresponding class will be loaded for the screen data entry. If the value picked is invalid, an error message will show on the form.
>
>On Valid method, I put the following code
>
>local oObject
>oObject = sys(1270) && object reference to the control the
> && user just clicked on
>
>if lastkey() = 27 .or. (type("oObject") = "O" .and. ;
> type("oObject.lCancel") = "L" .and. ;
> oObject.lCancel)
> return .t.
>endif
>
>return this.Validation()
>
>If I know what the inkey value for Close Button X, I could avoid to trigger the Validation() method. Any suggestions?
>
>Jim S

Move code from Valid to InteractiveChange event.
Edward Pikman
Independent Consultant
Previous
Reply
Map
View

Click here to load this message in the networking platform