Skip to content

Instantly share code, notes, and snippets.

@minitech
Created October 30, 2012 14:37
Show Gist options
  • Save minitech/3980564 to your computer and use it in GitHub Desktop.
Save minitech/3980564 to your computer and use it in GitHub Desktop.
A shutdown with confirmation for Windows 8 pinning
If MsgBox("Are you sure you want to shut down?", vbExclamation Or vbYesNo Or vbDefaultButton2, "Shut down") = vbYes Then
Dim wsh : Set wsh = CreateObject("WScript.Shell")
wsh.Run "shutdown /s /t 0"
End If
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment