Shell. ShutdownWindows, méthode
affiche la boîte de dialogue arrêter le Windows . Cela revient à cliquer sur le menu Démarrer et à sélectionner arrêter.
Syntaxe
iRetVal = Shell.ShutdownWindows()
Shell.ShutdownWindows() As Integer
Paramètres
Cette méthode n’a aucun paramètre.
Exemples
L’exemple suivant montre ShutdownWindows en cours d’utilisation. l’utilisation appropriée est indiquée pour JScript, VBScript et Visual Basic.
JScript :
<script language="JScript">
function fnShellShutdownWindowsJ()
{
var objShell = new ActiveXObject("shell.application");
objShell.ShutdownWindows();
}
</script>
VBScript
<script language="VBScript">
function fnShellShutdownWindowsVB()
dim objShell
set objShell = CreateObject("shell.application")
objShell.ShutdownWindows
set objShell = nothing
end function
Visual Basic :
Private Sub fnShellShutdownWindowsVB()
Dim objShell As Shell
Set objShell = New Shell
objShell.ShutdownWindows
Set objShell = Nothing
End Sub
Configuration requise
| Condition requise | Valeur |
|---|---|
| Client minimal pris en charge |
Windows 2000 Professional, Windows XP [ desktop apps uniquement] |
| Serveur minimal pris en charge |
Windows 2000 Server - [Applications de bureau uniquement] |
| En-tête |
|
| MIDL |
|
| DLL |
|