Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Why Cannot Quit Visual Foxpro On Shutdown?
Message
From
21/08/2007 19:26:55
Neil Mc Donald
Cencom Systems P/L
The Sun, Australia
 
 
To
21/08/2007 11:07:42
General information
Forum:
Visual FoxPro
Category:
Other
Environment versions
Visual FoxPro:
VFP 9 SP1
OS:
Windows XP SP2
Miscellaneous
Thread ID:
01249380
Message ID:
01249492
Views:
18
Hi,

This link gives code to check for dangling object references http://www.geocities.com/ResearchTriangle/9834/objref.zip

>If I kill MyProcess using Task Manager, no problem. But if I do a shutdown of my computer, I got a "Cannot Quit Visual Foxpro". What is missing in my code?
>
>*** MyProcess.PRG
>_screen.Visible = .f.
>oService = NEWOBJECT("vfpsvr")
>IF _vfp.StartMode > 0
>...READ EVENTS
>ENDIF
>CLOSE ALL
>RELEASE ALL
>QUIT
>
>DEFINE CLASS vfpsvr as Form
>...PROCEDURE Init
>......this.AddObject("mytimer","mytimer")
>......WITH this.mytimer
>..........enabled = .t.
>..........interval = 900000
>......ENDWITH
>...ENDPROC
>...PROCEDURE Destroy
>......CLEAR EVENTS
>...ENDPROC
>ENDDEFINE
>
>DEFINE CLASS mytimer as Timer
>...PROCEDURE timer
>......IF BETWEEN(DOW(DATE()),2,6) AND BETWEEN(VAL(LEFT(TIME(),2)),6,17)
>.........this.Enabled=.f.
>.........DO MyProcess
>.........this.Enabled=.t.
>......ENDIF
>...ENDPROC
>ENDDEFINE
>
>PROCEDURE MyProcess
>...
>...
>ENDPROC
Regards N Mc Donald
Previous
Reply
Map
View

Click here to load this message in the networking platform