Hi,
Is it possible to create a batch script that closes a program first before the PC is shutting down.
Thnx
batch script shutdown
Moderator: DosItHelp
-
- Posts: 100
- Joined: 16 Dec 2016 22:31
Re: batch script shutdown
As aGermen said in your last question a batch script not running can't do anything.
Though if you are triggering shutdown from a batch script(with shutdown command) you can just add a /f switch to force close all open windows or do a 'taskill' command(maybe a taskill and then a delaying loop with tasklist to ensure closing) to close that specific window.
Sounak
Though if you are triggering shutdown from a batch script(with shutdown command) you can just add a /f switch to force close all open windows or do a 'taskill' command(maybe a taskill and then a delaying loop with tasklist to ensure closing) to close that specific window.
Sounak