I'm on Windows 7 Home Premium.
I have a simple set of bat files. One to log me into work, one to log me out. All they do is open Firefox, ping Google, and clock me on or off. For months, Task Scheduler has run these religiously without problem.
Today, I ran into this:
- Task Scheduler deleted the .bat file halfway as it was running it.
- I tried to copy paste a backup file into the folder with the other .bat file, it told me I didn't have permissions.
- I re-took ownership of the folder, and the folder before it, and tried again. Task Scheduler deleted it and wrecked the permissions again.
- I tried putting the bat files in System32 thinking it surely wouldn't delete it from there. Task Scheduler deleted the bat files again.
- I've tried running the tasks with the "Hidden" option, and with the "Run with highest privilege" option. It continues to delete the file.
- The bat files themselves run perfectly well when I launch them manually. So it is something that Task Scheduler is doing that is causing this malfunction.
I've had Windows Update turned on for months so nothing could have gotten changed overnight.
I restarted and run system file checker, anti-virus, anti-malware, and a registry editor. The issue continues.
UPDATE: I created new tasks for the same bat files and they worked fine. The old tasks were causing the error. I'd still like to know, does anyone know why they did this spontaneously?