0

I run a program that needs to be closed by 10pm. I leave office at 9:30 PM. It would be wonderful if I had a script that closes this program automatically after 30 minutes. That would allow me to leave early and not have to wait to close it out maunally.

If I run the script below, it closes program instantly :(

import os
import time

# This program will attempt to close skype every 1 minute
while 1 :
    os.system("TASKKILL /F /IM skype.exe")
    time.sleep(60)
Carcigenicate
  • 43,494
  • 9
  • 68
  • 117
  • How are you running this? If it's closing, that would suggest that you're getting an error. Try running this in a different context and see if you get an error – Carcigenicate Mar 06 '20 at 21:55
  • You execute `TASKKILL /F /IM skype.exe` instantly. Why are you surprised? – DYZ Mar 06 '20 at 21:58

0 Answers0