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 SkipVought on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Mapping to aUNC Path

Status
Not open for further replies.

kachbo1

IS-IT--Management
Nov 16, 2004
40
0
0
GB
Hi,

I would like to map a couple unc paths using a vbscript. I just want to map to the paths, I do not want to use drive letters.

Is this possible?
 
when you say 'map' what do you mean then.
i was always under the impression that the act of 'mapping' involved the connection of a drive letter.

if you mean is it possible to manipulate files/folders on a server in a vbscript without the need of a drive mapping then the answer is yes, you can use UNC paths in GetFolders ect methods from the FSO object....
 
Yes I agree that I want to manipulate files/folders on a server in a vbscript without the need of a drive mapping.

Would appreciate if you could provide me with a script.
 
Set objFolder = FSO.GetFolder("\\server1\share1")

with FSO you need to have a share access point to get you started.

i seem to recall a number of posts on how to do it without a share being available using WMI
 
Set objNetwork = CreateObject("WScript.Network")
objNetwork.MapNetworkDrive "I:", "\\ServerName\ShareName
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top