I am trying to get a batch file to run according to a schedule in Windows 7. The computer seems to have other ideas and so far it is proving a fairly one sided battle of wills.
The idea - that it will run the batch file at 1910hrs each evening to move a file / group of files from a local folder on that PC to a network drive.
The problem - come the scheduled event nothing happens. If you choose to run the task now nothing happens either. It is almost as if the event is just being ignored. However drilling down into the Task Scheduler logs there are 8 references to it, confirming it was initiated, started and completed successfully. The unmoved files say otherwise. If you run the batch file by double clicking it it runs as designed.
So the file works and does its job when manually run which points the finger at the scheduler. The scheduling system appears to be working in that it calls the file at the scheduled time or when told to run now. But for some reason the file does not actually run when called by the scheduler. What have I done wrong?
The specifics are:
- Trigger at allotted time according to schedule.
- Action: Start a Program: C:\SW-BK\mv-bkp.bat
- Run as: DOMAIN\administrator
I have dumped a sizable chunk of files in that folder for testing purposes and it takes about 30 secs to move them all out again so the DOS window opened by the bat file should sit on the screen for quite some time when running. However it doesn't appear at all when run from the task scheduler which appears to confirm that it never actually starts.
The idea - that it will run the batch file at 1910hrs each evening to move a file / group of files from a local folder on that PC to a network drive.
The problem - come the scheduled event nothing happens. If you choose to run the task now nothing happens either. It is almost as if the event is just being ignored. However drilling down into the Task Scheduler logs there are 8 references to it, confirming it was initiated, started and completed successfully. The unmoved files say otherwise. If you run the batch file by double clicking it it runs as designed.
So the file works and does its job when manually run which points the finger at the scheduler. The scheduling system appears to be working in that it calls the file at the scheduled time or when told to run now. But for some reason the file does not actually run when called by the scheduler. What have I done wrong?
The specifics are:
- Trigger at allotted time according to schedule.
- Action: Start a Program: C:\SW-BK\mv-bkp.bat
- Run as: DOMAIN\administrator
I have dumped a sizable chunk of files in that folder for testing purposes and it takes about 30 secs to move them all out again so the DOS window opened by the bat file should sit on the screen for quite some time when running. However it doesn't appear at all when run from the task scheduler which appears to confirm that it never actually starts.