Close windows after 25 open hours

0

I have a specific program in Windows 7 that executes a certain process via a task scheduler, whose output is a simple web page that opens every 30 minutes. In this way I have just opened many windows of Internet Explorer which produce the saturation of the computer.

My intention is for these windows to close after 25 hours (each window individually), therefore the cmd /c taskkill /im /f iexplore.exe command does not work for me.

Note: I tried to solve it with the PID but when looking at the processes, I only had 2 iexplorer.exe processes running despite having several windows already open.

    
asked by Lagrimar 23.03.2017 в 14:41
source

2 answers

1

You could attack the problem from another perspective, if you have control over the simple web page, you can add a script that closes the page when a certain time passes.

setTimeout( function(){ window.close(); }, 90000000 ); // 90000000 = 25 hours
    
answered by 23.03.2017 / 18:03
source
0

The closest thing to what you are trying to do is taskkill /IM iexplorer.exe /FI "IMAGENAME eq (nombre de la ventana" , and even if this works for you in some way, you have to find a way to make the console wait 25 hours. I do not think batch will be of much use to you here.

    
answered by 16.04.2017 в 19:16