Public Declare Function ExitWindowSex Lib "User32" (Byval dwreserved as long) As long 'function declares EXITWINDOWSEX 1, 0' Turn off Computer 'EXITWINDOWSEX 0, 1' Restart Computer