Name of a CD in the CD drive

Forums for specific tips, techniques and example code
ConvertFromOldNGs
Posts: 5321
Joined: Wed Aug 05, 2009 5:19 pm

Name of a CD in the CD drive

Postby ConvertFromOldNGs » Fri Aug 07, 2009 2:24 pm

by Stephen Persson >> Thu, 4 May 2000 1:52:36 GMT

Does anyone know how to get the name of the CD currently in the CD drive?

I have an app which basically archives old reports etc.. to a CD writer. It also keeps track of the documents and which CD they were written to, so if the user wants to refer back to it later, it tells them to put CD say, Archive_01, in the CD reader, then loads the document for them.
I want to be able to check though if the CD named Archive_01 is already in the CD drive, so I don't prompt them to put in a CD thats already there.

Any ideas?

Stephen Persson
Kinetix

ConvertFromOldNGs
Posts: 5321
Joined: Wed Aug 05, 2009 5:19 pm

Re: Name of a CD in the CD drive

Postby ConvertFromOldNGs » Fri Aug 07, 2009 2:24 pm

by Carl Ranson >> Thu, 4 May 2000 2:14:48 GMT

I assume we're talking about the volume label here?

if so you can get that with the win32 call GetVolumeInformation. Documentation for this can be found at http://www.msdn.microsoft.com/library/d ... k/winbase/ fsys_6wfi.htm

regards,
CR

ConvertFromOldNGs
Posts: 5321
Joined: Wed Aug 05, 2009 5:19 pm

Re: Name of a CD in the CD drive

Postby ConvertFromOldNGs » Fri Aug 07, 2009 2:24 pm

by Craig Shearer >> Thu, 4 May 2000 2:19:02 GMT

I would have thought that this was the volume label for the drive. There would be a way to read this... certainly using a Windows API function, if not directly from JADE.

Craig.


Return to “Tips and Techniques”

Who is online

Users browsing this forum: No registered users and 6 guests