Batch file to copy file from one system to on [Solved/Closed]

vicky - Jun 10, 2008 at 02:48 AM - Latest reply:  div
- Apr 17, 2015 at 02:40 PM
Hello,

I have two systems ,one is domain member and other is workgroup computer.Now I want to shedule copy command for copying one file on daily basis from workgroup computer to domain member computer.

It is possible with batch file?

Workgroup computer Name :-hisserver
user :administrator
password :hisserver

Domain Member :hisbackup
user : administrator
Password:*healthbackup
See more 

12 replies

Best answer
getsugatenso - Jun 11, 2008 at 03:51 AM
22
Thank you
xcopy directory [destination-directory]

and then turn this into a .BAT file

Thank you, getsugatenso 22

Something to say? Add comment

CCM has helped 1678 users this month

9
Thank you
mudbrains, can you explain the purpose of this statement in your code?
set path=c:\WINDOWS\system32;
6
Thank you
Hi,

Please try the following batch command......





set path=c:\WINDOWS\system32;

echo Copying started at %date% %time%>>_date_.txt

xcopy E:\backup \\SERVER\BACKUP\others /s /a /d

echo Copying finished at %date% %time%>>_date_.txt

echo Completed Successfully at %date% %time%>>_date_.txt

echo --------------------------------------------------------------------------- >>_date_.txt

pause
hi I have tired this way but it shows me erros,,,,iam trying to copy a file from my local machine(vista) to a remote machine(windows2003) and I am trying to copy a file from from
my c:\folder to c:\transfer in remote machine and I have given same command lines and it doesnot.

i have given like this xcopy c:\practicetemp \\10.65.1.71 C:\transfer /s/a/d

rest is same,,,,,,,it gives invalid num of parameters
Dhritiman (SQL DBA) - Mar 18, 2015 at 04:00 AM
great..it works..thanks
3
Thank you
We can use NET USE COMMAND to connect to a remote computer
yes but psexec should have been installed on remote machine
2
Thank you
Right click Command Promt and choose Run As - Administrator (local or domain)
Run the batch file from the Commnad Promt windows just open.
1
Thank you
but how will the networ drive get mapped

what about username and password


regards
ambrish
Hi,

No need to map the network, allow permission in the server backup directory for that domain user.

Thanks
JJ
Tom > Mudbrains - Sep 2, 2009 at 12:32 PM
Ok, what if I wanted to Sync files from a Windows PC using an FTP Network Connection that has been defined and works just fine.

I want to use that connection to SYNC to a remote server.

I'd like to create a batch file that I can add to my Task Scheduler.