views:

298

answers:

2

I having server folder as a mapped network drive in workstation . Now the that folder is shifting to to another server so Ineed to change the path this activity I need to do at 400 workstations. so can you help me with script.

+1  A: 

If your old drive mapping is in O: you use this to delete it:

net use /d O:

And this to create the new one:

net use O: \\newserver\\newpath /PERSISTENT:YES

If you have to specify a username \ password:

net use O: \\newserver\\newpath password /USER:domain\user /PERSISTENT:YES
jeffamaphone
A: 

Given drive Letter g:

net use g: /delete
net use g: "\\server\share"

It's important to use the quotes around the path, otherwise paths with spaces will not map correctly.

Jonathan