Dos AT command

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

I have mapped a drive on my local computer to a file server. I created a
batch file to copy files from the server onto the local machine. If I type in
the name of the batch file at a command prompt it executes correctly. I now
want it to run at night. I have tried the AT command on both Windows 2000 and
XP with no success. Here is an example of what I have entered:
AT 1:30am /every:monday c:\mon.bat /s /e /h /y
When I come in the next morning, nothing has copied. Can someone please help.
 
monorato said:
I have mapped a drive on my local computer to a file server. I created a
batch file to copy files from the server onto the local machine. If I type
in
the name of the batch file at a command prompt it executes correctly. I
now
want it to run at night. I have tried the AT command on both Windows 2000
and
XP with no success. Here is an example of what I have entered:
AT 1:30am /every:monday c:\mon.bat /s /e /h /y
When I come in the next morning, nothing has copied. Can someone please
help.

use "scheduled tasks" in control panel
 
I have tried to run it in scheduled tasks, but I can't get it to work. It
says that it ran the task, but the files have not copied. When I use the task
wizard, I browse and select the batch file to run, set date and time.
Nothing. I am missing something with the setup?
 
You will have to map the drive in the batch file before you do the copy.
Does it make sense no but try it.
 
When I try to map, dos tells me that it is not recognized as an internal or
external command, operable program or batch file.
 
monorato said:
I have mapped a drive on my local computer to a file server. I created a
batch file to copy files from the server onto the local machine. If I type in
the name of the batch file at a command prompt it executes correctly. I now
want it to run at night. I have tried the AT command on both Windows 2000 and
XP with no success. Here is an example of what I have entered:
AT 1:30am /every:monday c:\mon.bat /s /e /h /y
When I come in the next morning, nothing has copied. Can someone please help.

Give yourself some eyes so that you can see what's going
on. Instead of invoking c:\mon.bat, invoke this batch file:

Line1 @echo off
Line2 echo %date% %time% Start of task > c:\test.log
Line3 echo User=%UserName%, Path=%path% >> c:\test.log
Line4 xcopy.exe /s /e /h /y "c:\SourceFolder" "d:\DestFolder\"
1>>c:\test.log 2>c:\test.err
Line5 echo ErrorLevel of c:\Tools\YourTask.exe=%ErrorLevel% >> c:\test.log
Line6 echo %date% %time% End of task >> c:\test.log

Examine the two log files after the job has run!

Note that at.exe will run the batch file under the System
account. This account has no access rights to networked
resources. Use the Task Scheduler as suggested by other
respondents if copying to a networked drive.
 

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

Back
Top