SumTingWong Posted August 6, 2004 Share Posted August 6, 2004 In the absence of a built-in DriveMapEnum, here's a little something to fill the gap Dim $s, $i ; Usage example $s = _DriveMapEnum() MsgBox(4096,'debug:' , '$s:' & $s[0]);### Debug MSGBOX For $i = 1 To $s[0] Step 2 MsgBox(4096,'debug:' , $s[$i] & " - " & $s[$i+1]);### Debug MSGBOX Next Func _DriveMapEnum() Local $aNULL[1] Local $i Local $sMap Local $sMapList = "" For $i = 68 To 90 $sMap = DriveMapGet(Chr($i) & ":") If $sMap <> "" Then $sMapList = $sMapList & Chr($i) & ":*" & $sMap & "*" Next If StringRight($sMapList, 1) = "*" Then $sMapList = StringLeft($sMapList, StringLen($sMapList)-1) Return StringSplit($sMapList, "*") Else $aNULL[0] = 0 Return $aNULL EndIf EndFunc 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