DWORD ReadTOC( HCDROM hCD, LPTOC lpTOC );


Description: Reads the Table of Contents (TOC) from a given CD-ROM.

Parameters:
hCD Handle to the CD-ROM unit
lpTOC Pointer to a TOC structure to receive the read TOC.

Return Value:

SS_COMP TOC read successfully
SS_ERR An error occured. Use GetAspiLibError to retrieve the specific error code.

Notes: The TOC on a CD-ROM can contain 99 entries -- there must be at least one entry for the lead-out area. The TOC structure, after being read by this function, will contain a 1-based index of the first and last tracks. The format returned will be either LBA or MSF (minute:second:frame) -- the default format is LBA, but by calling ModifyCDParms( hCD, CDP_MSF, TRUE ), you can set the format to MSF.

See also: GetCDHandle, GetAspiLibError