command line to shutdown internet explorer

  • Thread starter Thread starter Guest
  • Start date Start date
spinkid said:
Does anyone know how to shutdown Internet Explorer 7.0 from the
command-line?

Yes. Write this down so you can remember it:

shutdown

Use
shutdown /?
in a command box to see all the switches available.
 
This command only shuts down the computer. I just want to shutdown an open
Interent Explorer window not reboot the computer.
 
Thanks that worked. However I also found some vbs code that would work as
well.

strComputer = "."
Set objWMIService = GetObject("winmgmts:" _
& "{impersonationLevel=impersonate}!\\" & strComputer & "\root\cimv2")

Set colProcessList = objWMIService.ExecQuery _
("Select * from Win32_Process Where Name = 'iexplore.exe'")

For Each objProcess in colProcessList
objProcess.Terminate()
Next
 
Back
Top