I need to catch the shutdown event from a computer in a VB
App.
I search the MSDN and found the ExitWindow(Ex) but this
API realize the shutdown and don't catch the event.
Could you help me?
And so if you can give me the windows start event, I will
be very happy.
Cette action est irreversible, confirmez la suppression du commentaire ?
Signaler le commentaire
Veuillez sélectionner un problème
Nudité
Violence
Harcèlement
Fraude
Vente illégale
Discours haineux
Terrorisme
Autre
François Picalausa
"JM" a écrit dans le message de news:080201c3c944$2ac1aa00$
I need to catch the shutdown event from a computer in a VB
Bonjour/soir,
fr.vb, ça veut dire qu'on est dans un groupe francophone ;-)
Tu as l'événement QueryUnload d'une form qui peut t'aider. unloadMode, lrosuq'il vaut vbAppWindows signifie que "The current Microsoft Windows operating environment session is ending."
En ayant une feuille invisible, tu peux donc facilement récupérer cette valeur.
Exemple: Option Explicit
Private Sub Form_Load() Me.Visible = False End Sub
Private Sub Form_QueryUnload(Cancel As Integer, UnloadMode As Integer) If UnloadMode = vbAppWindows Then MsgBox "La session est en cours de fermeture" End If End Sub
"JM" <jerome.masset@cegedim.fr> a écrit dans le message de
news:080201c3c944$2ac1aa00$a301280a@phx.gbl
I need to catch the shutdown event from a computer in a VB
Bonjour/soir,
fr.vb, ça veut dire qu'on est dans un groupe francophone ;-)
Tu as l'événement QueryUnload d'une form qui peut t'aider. unloadMode,
lrosuq'il vaut vbAppWindows signifie que "The current Microsoft Windows
operating environment session is ending."
En ayant une feuille invisible, tu peux donc facilement récupérer cette
valeur.
Exemple:
Option Explicit
Private Sub Form_Load()
Me.Visible = False
End Sub
Private Sub Form_QueryUnload(Cancel As Integer, UnloadMode As Integer)
If UnloadMode = vbAppWindows Then
MsgBox "La session est en cours de fermeture"
End If
End Sub
"JM" a écrit dans le message de news:080201c3c944$2ac1aa00$
I need to catch the shutdown event from a computer in a VB
Bonjour/soir,
fr.vb, ça veut dire qu'on est dans un groupe francophone ;-)
Tu as l'événement QueryUnload d'une form qui peut t'aider. unloadMode, lrosuq'il vaut vbAppWindows signifie que "The current Microsoft Windows operating environment session is ending."
En ayant une feuille invisible, tu peux donc facilement récupérer cette valeur.
Exemple: Option Explicit
Private Sub Form_Load() Me.Visible = False End Sub
Private Sub Form_QueryUnload(Cancel As Integer, UnloadMode As Integer) If UnloadMode = vbAppWindows Then MsgBox "La session est en cours de fermeture" End If End Sub