Quitting out of Apps. 
Author Message
 Quitting out of Apps.

Hi all,

VB 3.0 Pro

        How do I stop a user from quitting out of windows while my App
is still running. (Like the DOS Prompt does)?

Thanks for any help anyone can give me.

        Steve
--
GameNet Systems.
Steve Carrington.



Sun, 07 Feb 1999 03:00:00 GMT  
 Quitting out of Apps.

: Hi all,

: VB 3.0 Pro

:         How do I stop a user from quitting out of windows while my App
: is still running. (Like the DOS Prompt does)?

The most direct (and easiest) way is to go into you main form's QueryUnload
event.  From there, put in a line of code to check if your program is done.
If it isn't, use 'cancel = true'.

This will stop the shut down.

-Patrick
 http://www.tjhsst.edu/people/pmcneill/



Mon, 08 Feb 1999 03:00:00 GMT  
 Quitting out of Apps.

Taken directly out of the help-file for VB :-<

Sub MDIForm_QueryUnload (Cancel As Integer, UnloadMode As Integer)

        Dim Msg ' Declare variable.

        ' Set the message text.
        Msg = "Do you really want to exit the application?"
        ' If user clicks the 'No' button, stop QueryUnload.
        If MsgBox(Msg, 36, Me.Caption) = 7 Then Cancel = True
End Sub

Dag.
___________________________

Quote:

> Hi all,

> VB 3.0 Pro

>         How do I stop a user from quitting out of windows while my App
> is still running. (Like the DOS Prompt does)?

> Thanks for any help anyone can give me.

>         Steve
> --
> GameNet Systems.
> Steve Carrington.




Mon, 08 Feb 1999 03:00:00 GMT  
 Quitting out of Apps.

Quote:

>VB 3.0 Pro
>        How do I stop a user from quitting out of windows while my App
>is still running. (Like the DOS Prompt does)?

In the form_QueryUnload-event set CANCEL=TRUE.

Rainer

------------------------------------------------------



Tue, 16 Feb 1999 03:00:00 GMT  
 
 [ 4 post ] 

 Relevant Pages 

1. PREVENTING USER FROM QUITTING APP

2. Word 2000: VB app wants to wait for it to quit

3. Pausing App.Quit till After Printing

4. XP Bug - DocumentBeforeClose doesn't fire for successive docs on App Quit

5. Quitting Apps which use OLE server

6. hta app crashes on quit ?

7. Quit App

8. VB App hanging around--won't quit

9. Forcing another app to quit...

10. university EMR send outs

11. on the outs

12. Learning the ins and outs of Peek and Poke

 

 
Powered by phpBB® Forum Software