简体   繁体   中英

Command line to copy files from remote location

I want to write a script that will copy some files from LAN computer to my pc. I don't know what would be the syntax of this command.

Could anyone help me related to this?

One thing more, that in my case both the machines are using Windows.

xcopy /z \\myServer\myFolder c:\

/Z Copies networked files in restartable mode.

where \\myServer\\myFolder is a unc path , or if you have network drive ( for example o: ) so use :

xcopy /z o: c:\
  1. net.exe use to map remote share to temporary drive letter
  2. copy or robocopy or xcopy or whever to copy the files
  3. net.exe use to remove used mapping and free the letter

Note that Windows (95/98/ME) and WindowsNT ( NT3 / NT$ / 2000 / XP / Vista / 7) are radically different operating systems and have different DOS commands and options, especialy regarding copying.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM