cs_brodeur
Messages postés15Date d'inscriptionjeudi 28 février 2002StatutMembreDernière intervention28 septembre 2006
-
19 juin 2002 à 13:41
cs_brodeur
Messages postés15Date d'inscriptionjeudi 28 février 2002StatutMembreDernière intervention28 septembre 2006
-
19 juin 2002 à 16:27
Bonjour
Est-ce que vous connaisez la fonction de fermeture de windows ( ou la procedure ) sous VB6. L'ancienne fonction que j'utilisait marchait sous 98 et me mais ca marche plus sous 2000.
Koment ke je dois faire ?
Merci de votre aide.
cs_thitoune
Messages postés124Date d'inscriptionmardi 19 février 2002StatutMembreDernière intervention 7 mars 20042 19 juin 2002 à 14:21
(Ce n'est pas de moi)
Const EWX_FORCE = 4
Const EWX_LOGOFF = 0
Const EWX_REBOOT = 2
Const EWX_SHUTDOWN = 1
Declare Function ExitWindowsEx Lib "user32" _
(ByVal uFlags As Long, ByVal dwReserved As Long) As Long
Function RestartWindows() As Boolean
RestartWindows = CBool(ExitWindowsEx(EWX_REBOOT, 0))
End Function
Function ShutDownPC() As Boolean
ShutDownPC = CBool(ExitWindowsEx(EWX_SHUTDOWN, 0))
End Function
Function LogOffPC() As Boolean
ShutDownPC = CBool(ExitWindowsEx(EWX_LOGOFF, 0))
End Function