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 TouchToneTommy on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Form Close

Status
Not open for further replies.

sheronne

Programmer
Jun 1, 2001
71
US
When the user presses the close button in the control box, is there anyway to have it ask if the user actually wants to close or just minimize the screen?

Hope this makes sense.

Thanks
 
You can execute code for that event using the 'ON SHUTDOWN' command. Check out the help file.

Brian
 
Sheronne,

If you are referring to the close button on a form, put code in the form's QueryUnload event. Display a messagebox to ask the question. If the user says they don't want to close after all, issue NODEFAULT, otherwise do nothing.

If you are referring to the close button in the main VFP window, see Brian's reply above.

Mike




Mike Lewis
Edinburgh, Scotland
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top