Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Closing Dialog Boxes 2

Status
Not open for further replies.

reinaldo

Programmer
Mar 29, 2001
31
US
I have a form (Dialog Box) called "Print" , can someone tell me how to close the form using the escape key?

thank you
 
Edit the forms keyphysical event:

method keyPhysical(var eventInfo KeyEvent)

if eventInfo.isPreFilter() then
;// This code executes for each object on the form

else
;// This code executes only for the form
if eventinfo.vcharcode() = VK_ESCAPE then
self.close()
endif
endIf

endMethod

Richie
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top