Hi all-
Been having a problem with temp ".dbf" files remaining in my active directory when a program is prematurely shutdown due to user not exiting the program properly,power failure, etc.
I have a program that checks to see if a temp file exists, and if it exists, make sure it's closed, then delete it. I named this .prg "Closedbfs"
My ON SHUTDOWN command should kick in at these points but doesnt always delete my files. I dont' get it.
This is the code behind my "Quit" button on my form -
thisform.release()
DO clr_sets
SET SYSMENU TO DEFAULT
set talk off
CLEAR
DO QUITAPP
close all
close databases
release all
on shutdown
Then in my "main" driver program I have:
On SHUTDOWN
Do closedbfs
Clear Events
Close Databases All
Set Sysmenu To Default
Clear All
Close All
Am I issuing the ON SHUTDOWN command properly? Please - any help is appreciated.
Thanks
Angie
Been having a problem with temp ".dbf" files remaining in my active directory when a program is prematurely shutdown due to user not exiting the program properly,power failure, etc.
I have a program that checks to see if a temp file exists, and if it exists, make sure it's closed, then delete it. I named this .prg "Closedbfs"
My ON SHUTDOWN command should kick in at these points but doesnt always delete my files. I dont' get it.
This is the code behind my "Quit" button on my form -
thisform.release()
DO clr_sets
SET SYSMENU TO DEFAULT
set talk off
CLEAR
DO QUITAPP
close all
close databases
release all
on shutdown
Then in my "main" driver program I have:
On SHUTDOWN
Do closedbfs
Clear Events
Close Databases All
Set Sysmenu To Default
Clear All
Close All
Am I issuing the ON SHUTDOWN command properly? Please - any help is appreciated.
Thanks
Angie