How does one obtain the CD Drive letter of a user's machine?

What are the commands for accessing the Registry? Are these done only with WinAPI?

Thanks.