Logo 
Search:

MS Office Answers

Ask Question   UnAnswered
Home » Forum » MS Office       RSS Feeds
  Question Asked By: Joel Evans   on Feb 23 In MS Office Category.

  
Question Answered By: Aabirah Khan   on Feb 23

I can offer you a partial solution. This code will map  a drive  if it
can. The error portion of the code you can attempt a different drive,
or whatever.

Sub Map()
On Error GoTo MapError

Set Map = CreateObject("WScript.Network")
Map.MapNetworkDrive "F:", "\\server\folder", , "UserName", "Password"

Set Map = Nothing

MapError:
MsgBox ("F is connected already")

End Sub


I'm not  sure how to verify password/username accuracy.

Share: 

 

This Question has 1 more answer(s). View Complete Question Thread

 
Didn't find what you were looking for? Find more on Mapping Network Drive Or get search suggestion and latest updates.


Tagged: