Starting Schedule Task Via Batch File

G

Guest

How does one overcome a /WAIT statement issue where the wait really does not
wait until the process is finished. I have two lines of code in a batch file:

Line1 = start /wait schtask /run /nt "name of task"
Line2 = rename a file created from the task of Line1

Line1 runs backup software creating a flat file; Line2 renames the flat file
to something else.

When the batch file runs Line2 is executed and fails due to the fact that
the flat file isn't created yet. This is simply a timing issue.

Thanks-John
 
G

Guest

Kelly,

Thanks for the link. The only thing I could locate via a search was to 3rd
party software to run batch file. My issue is more of a timing issue
(waiting for the backup program to write to a file). Then proceed to the
next line of code. In theory the /wait command should work but does not.
Still waiting.... Thanks and a Happy Holiday to you too - John
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top