Nomi Khan
Nomi Khan

Reputation: 1197

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.

Upvotes: 2

Views: 20183

Answers (2)

Arioch 'The
Arioch 'The

Reputation: 16045

  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.

Upvotes: 3

Royi Namir
Royi Namir

Reputation: 148524

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:\

Upvotes: 3

Related Questions