Mrinaldi Posted September 11, 2007 Share Posted September 11, 2007 I'm a bit lost on how to do this but here goes. I need to disconnect a mapped drive but I have no idea what the drive letter is but I do know the share. so on the pc's we have some unknown drive letter mapped to \\server\share i have tried DriveMapDel('\\sever\share') but it wont disconnect any suggestions will be helpful Link to comment Share on other sites More sharing options...
bogQ Posted September 11, 2007 Share Posted September 11, 2007 (edited) I'm a bit lost on how to do this but here goes. I need to disconnect a mapped drive but I have no idea what the drive letter is but I do know the share.so on the pc's we have some unknown drive letter mapped to \\server\share i have tried DriveMapDel('\\sever\share') but it wont disconnect any suggestions will be helpfulyou need the name (device) of map drive DriveMapDel("X:")not his remote shareEdit: see the proporties and with autoit info copy the drive leter if you dont know difrent way>>>> Visible Text <<<<GeneralType:Network DriveFile system:FATzUsed space:20.579.729.408 bytes19,1 GBFree space:10.866.556.928 bytes10,1 GBCapacity:31.446.286.336 bytes29,2 GBDrive Z Edited September 11, 2007 by bogQ TCP server and client - Learning about TCP servers and clients connectionAu3 oIrrlicht - Irrlicht projectAu3impact - Another 3D DLL game engine for autoit. (3impact 3Drad related) There are those that believe that the perfect heist lies in the preparation.Some say that it’s all in the timing, seizing the right opportunity. Others even say it’s the ability to leave no trace behind, be a ghost. Link to comment Share on other sites More sharing options...
Developers Jos Posted September 11, 2007 Developers Share Posted September 11, 2007 something like this ? (Untested) Func DriveMadDeleteUNC($UNC) $var = DriveGetDrive("NETWORK") If Not @error Then For $i = 1 To $var[0] If $UNC = DriveMapGet($var[$i]) Then DriveMapDel($var[$i]) Next EndIf EndFunc ;==>DriveMadDeleteUNC SciTE4AutoIt3 Full installer Download page - Beta files Read before posting How to post scriptsource Forum etiquette Forum Rules Live for the present, Dream of the future, Learn from the past. Link to comment Share on other sites More sharing options...
Mrinaldi Posted September 11, 2007 Author Share Posted September 11, 2007 something like this ? (Untested) Func DriveMadDeleteUNC($UNC) $var = DriveGetDrive("NETWORK") If Not @error Then For $i = 1 To $var[0] If $UNC = DriveMapGet($var[$i]) Then DriveMapDel($var[$i]) Next EndIf EndFunc ;==>DriveMadDeleteUNC worked like a charm thank you Link to comment Share on other sites More sharing options...
Recommended Posts
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 accountSign in
Already have an account? Sign in here.
Sign In Now