Tech Support > Operating Systems > Windows 2000 > Which file is it?
Which file is it?
Posted by DVS on February 12th, 2004


In the XP OS, there is a file called shutdown.exe in the
WINNT\System32 folder that you can use with different
switches to shutdown, restart....

There is no shutdown.exe file in Windows 2000. Does
anyone know what file is called when you want to shut down?

TIA,
DVS

Posted by Dave Patrick on February 12th, 2004


shutdown.exe is in the Windows 2000 resource kit.

Other possibilities;

psshutdown from sysinternals
http://www.sysinternals.com/ntw2k/fr...shutdown.shtml

VBScript
-------------------------------
'0 Log Off
'4 Forced Log Off
'1 Shutdown
'5 Forced Shutdown
'2 Reboot
'6 Forced Reboot
'8 Power Off
'12 Forced Power Off
Const SHUTDOWN = 1
strComputer = "."
Set objWMIService = GetObject("winmgmts: {(Shutdown)}" _
& "{impersonationLevel=impersonate}!\\" & strComputer & "\root\cimv2")
Set colOperatingSystems = objWMIService.ExecQuery _
("SELECT * FROM Win32_OperatingSystem")
For Each objOperatingSystem in colOperatingSystems
ObjOperatingSystem.Win32Shutdown(SHUTDOWN)
Next
-------------------------------

--
Regards,

Dave Patrick ....Please no email replies - reply in newsgroup.
Microsoft MVP [Windows NT/2000 Operating Systems]
Microsoft Certified Professional [Windows 2000]
http://www.microsoft.com/protect


"DVS" wrote:
| In the XP OS, there is a file called shutdown.exe in the
| WINNT\System32 folder that you can use with different
| switches to shutdown, restart....
|
| There is no shutdown.exe file in Windows 2000. Does
| anyone know what file is called when you want to shut down?
|
| TIA,
| DVS