The following code results in "Drive D: is not read (no media present)" whenever a BLANK (brand new) CD-RW is in the drive. How can I detect that a blank CD-RW is in the drive? There is no "IsBlank" property that I can find. I'm trying to determine if there is anything on the media and, if there is, the script erases the media (using CreateCD). Note that there is nothing wrong with the media (I've tried several disks, and can write on them fine. Once I've written on them, my script detects the media in the drive)
'*** Make sure CD-RW drive read
TestDrive = "D:
Set TestDriveObject = fso.GetDrive(TestDrive
If Not TestDriveObject.IsReady the
PromptStr = "Drive " & TestDrive & " is not ready (no media present)
PromptStr = PromptStr & CrLf & "Script terminated due to error
PromptButtons = vbOKOnly + vbCritica
ScriptExitCode = 9
TerminateScrip
End if