A script I have that checks if an external HDD is connected, which has a prompt to mount the drive, with the option 'retry' and 'cancel'. If I click 'retry' it says it has found the drive, even though it's not connected, how can I fix this ?
Jump to Post
const DRIVE = "F" set fso = CreateObject("Scripting.FileSystemObject") On Error Resume Next Do set drv = fso.Drives(DRIVE) if err.Number = 0 then Exit Do If MsgBox("Drive " & DRIVE & ": is not available, Please mount the drive", vbRetryCancel, "Test") = vbCancel Then Wscript.Quit End …
All 12 Replies
Be a part of the DaniWeb community
We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, learning, and sharing knowledge.