Josh,
Thanks for both pointers, they were exactly what I was looking for!
Rgds
Ashley
>Ashley,
>
>Check out the help for ON SHUTDOWN to close your application when the user clicks the close box. Basically, you do ON SHUTDOWN MyProg, then put the QUIT command in MyProg. This allows you to do any necessary cleanup or to keep the application from exiting at certain points.
>
>To keep from running multiple instances of your application, check out the Microsoft knowledge base article at
http://support.microsoft.com/support/kb/articles/q109/0/59.asp>
>I think there's also something in the knowledge base here at the UT.
>
>>Hi,
>>
>>I'd like to know if I can make my application close when the Main Visual Foxpro screen close icon is clicked.
>>
>>Also would appreciate suggestions as to how to stop multiple instances of my application from being executed.
>>
>>TIA