Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Trouble with QUIT
Message
 
To
All
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Title:
Trouble with QUIT
Miscellaneous
Thread ID:
00756424
Message ID:
00756424
Views:
47
Hi,

I have some trouble with my Quit statements.

Main Program:

On Shutdown Do PrgExit
IF CHECKVERSION()
IF OpenFile()
DO form LOGON
else
=MESSAGEBOX( "There has been an error trying to prepare the program.", 16 , "Connect and Open Database Error" )
RETURN
EndIf
EndIf

CheckVersion()

m.xmessage = "I am about to update your PC."+CHR(13)+"Shall I proceed?"
m.xopt=MESSAGEBOX( m.xmessage , 36 , "Upgrade Option" )
IF m.xopt=6
DO UpdatePC
ELSE
=MESSAGEBOX( "You have chosen not to update your PC. Program will be terminated." , 48 , "Upgrade Aborted" )
Quit
ENDIF


PrgExit()

CLOSE DATABASES ALL
CLOSE ALL
RELEASE ALL
CLEAR MEMORY
ON ERROR
ON SHUTDOWN
CLEAR EVENTS

But after the checkversion program executes the QUIT command, instead of quiting the application, the prgexit() program is executed and the control returns to the MAIN program.

What am I doing wrong? Thanks.

Ria
Next
Reply
Map
View

Click here to load this message in the networking platform