Sarah,
I think you want to check the QueryUnload() method. In QueryUnload of my data form I put in:
NODEF
thisform.close()
thisform.close() is defined by myself and has all the code for a clean close.
Chen
>If I make a form "closeable" how do I know if that's how the user has closed a form.
>
>Best way I can see is to create a property called lActivelyClosed and my close buttons set this to .T. and then my destroy event runs some code if it's .F.
>
>Or have I missed something, it was late at night when I was researching this...
>
>Thanks
>
>Sarah
Chen Nan