How do you detect when Windows is shutting down using Vb ?

Thank you

Please forward your solution to [email protected] or just reply.

Thank you again.

Yandisa Mtyide

Comments

  • : Thank you
    :
    : Please forward your solution to [email protected] or just reply.
    :
    : Thank you again.
    :
    : Yandisa Mtyide
    :
    Private Sub Form_QueryUnload(Cancel As Integer, UnloadMode As Integer)

    'vbFormControlMenu 0 The user chose the Close command from the Control menu on the form.
    'vbFormCode 1 The Unload statement is invoked from code.
    'vbAppWindows 2 The current Microsoft Windows operating environment session is ending.
    'vbAppTaskManager 3 The Microsoft Windows Task Manager is closing the application.
    'vbFormMDIForm 4 An MDI child form is closing because the MDI form is closing.
    Select Case UnloadMode

    Case vbAppWindows
    'The current Microsoft Windows operating environment session is ending.
    Case Else

    End Select

    End Sub

Sign In or Register to comment.

Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!

Categories

In this Discussion