Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations derfloh on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Copying files from a server to multiple computers

Status
Not open for further replies.

LeanneGodney

Technical User
Mar 7, 2002
175
GB
Hi there,

I need to set up some code that will copy a set of files and subfolders from a server to about 10 machines. I'd like to be able to run this code from one machine and it must copy the files to each of the said machines. Can I do this from VBA? And can it be packaged into an executable file on the desktop for double clicking?

If so, then how?

Thanks in advance,
Leanne
 
I guess it depends on what rights you have. If you are an administrator then you can often view peoples hard drives. Then it's just a case of writing a batch file that copies to the path youhave assigned.
Another way would be to get the administrator to create a log in script that does it for you each time they log in.
AFAIK, these are the only ways of doing it remotley, other than sending the users a file that they run themselves to bring the data over.

B ----------------------------------
Ben O'Hara
bo104@westyorkshire.pnn.police.uk
----------------------------------
 
Aaah, that's quite a good idea - the logon script thing. I'll speak to my administrator.

The other thing is to perhaps put a batch file into the startup I suppose. If I did this, what would I type in there?

I wanted to deltree whatever folders were inside c:\exercises, and then xcopy from the server to c:\exercises.

Would this work?

md c:\exercises
deltree c:\exercises\*.*
xcopy \\traindom\Trainserver\Evaluation\*.* c:\exercises
 
That's what the login script does, it runs every time the user logs into the PC.
Another thing to look for would be robocopy. It's part of the Network Administrators Kit I think, but basically you can set it up to copy a directory from 1 place to another, and get rid of any files or folders in the destination folder that aren't in the source folder.

robocopy \\wyp_mans_1\perfweb$\abstractions\ /purge

HTH

Ben ----------------------------------
Ben O'Hara
bo104@westyorkshire.pnn.police.uk
----------------------------------
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top