Jump to content

Recommended Posts

Here is what I am trying to do.

Windows NT/2000 enviroment. Its mostly 2000 till the NT servers get converted to 2000 file servers.

I know this script below will enumerate mapped drives.

Set WshNetwork = WScript.CreateObject("WScript.Network")
        Set oDrives = WshNetwork.EnumNetworkDrives
                 For i = 0 to oDrives.Count - 1 Step 2
           ''WScript.Echo "Drive " & oDrives.Item(i) & " = " & oDrives.Item(i+1)
        Next
        WScript.Echo
       

and the map script is

Set WshNetwork = WScript.CreateObject("WScript.Network")
WshNetwork.MapNetworkDrive "E:", "\\Server\FolderName"

So my end result is I want it check for mapped drives and if it finds them remap with the user choosing the drive letter since we have over 30+possible folder names that could be mapped otherwise I would map it to a particular drive all the time.

But I do need to exclude M drive though since its global and will always be there for user for storage/backup of files.

Link to comment
Share on other sites


Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...