Troubleshooting Error Code 80070055 – The local device is already in use
Introduction to Error Code 80070055
The Symptoms You Get 80070055
When you execute the VBScript you get a WSH (Windows Script Host) message box like this diagram opposite. The script does not execute as you had hoped.
The Cause of Error 80070055
One possibility is that you trying to map a network drive but the drive letter you wish to use has already been assigned. Perhaps you have already run the script once, and now you double click the .vbs file one more time. Alternatively, you have forgotten that the H:\ or K:\ drive letter is a physical drive on this particular machine.
Another cause could be your VBScript contains an illegal LDAP reference, probably a typing mistake, maybe an extra letter. Check the spelling of your objects in the script.
Another clue is the Source: WSHNetwork.MapNetworkDrive. A clear indication that the MapNetworkDrive method is causing the error.
For ‘The local device name is already in use’, check your drive letters and printers, in particular lookout for potential duplicates. You could also try the free Kiwi Syslog Server network utility
The Solutions for The local device is already in use
To examine the drive letters, open windows explorer and check the local drive letters against the DriveLetter used in your script. In this example it is the K: drive which is causing the problem.
Another cause could be a syntax error. Check or adjust the slashes in your path.
For example: RemotePath = "\\ alan\home" is correct.
Under different circumstance is could be a duplicate printer. So check the printer folder to see what printers have already been installed.
This Engineer’s Toolset v10 provides a comprehensive console of 50 utilities for troubleshooting computer problems. Guy says it helps me monitor what’s occurring on the network, and each tool teaches me more about how the underlying system operates.
There are so many good gadgets; it’s like having free rein of a sweetshop. Thankfully the utilities are displayed logically: monitoring, network discovery, diagnostic, and Cisco tools. Try the SolarWinds Engineer’s Toolset now!
Example Script for Error 80070055
GuyNet.MapNetworkDrive DriveLetter, RemotePath
The DriveLetter corresponds to K: and the problem was that the drive letter was already mapped.
‘Purpose of the script is to Connect or Disconnect the K drive
Set WshShell = WScript.CreateObject("WScript.Shell")
DriveLetter = "K:" ‘DriveLetter must be a CAPITAL letter
AlreadyConnected = False
If AlreadyConnected = True then
Windows Management Instrumentation (WMI) is one of the hidden treasures of Microsoft operating systems. Fortunately, SolarWinds have created the WMI Monitor so that you can examine these gems of performance information for free. Take the guess work out of which WMI counters to use for applications like Microsoft Active Directory, SQL or Exchange Server.
Do you need additional help?
Give something back?
Would you like to help others? If you have a good example of this error, then please email me, I will publish it with a credit to you:
If you like this page then please share it with your friends