Copyright © 2005-2019 MultiMedia Soft

GetCdDriveLetter method

Previous pageReturn to chapter overviewNext page

Remarks

 

Retrieves the drive letter of the requested CD drive: for example it will return "D" (without quotes) for the drive "D:\".

 

The total number of available CD drives can be obtained using the GetCdDrivesCount method.

 

 

Syntax

 

[Visual Basic]

Public Function GetCdDriveLetter (

nDriveIndex as Int16

) as String


 

[C#]

public string GetCdDriveLetter (

Int16 nDriveIndex

);


 

[C++]

public: string GetCdDriveLetter (

Int16 nDriveIndex

);


 

 

Parameter

Description

 

 

nDriveIndex

Number representing the zero-based index of the CD drive whose letter must be retrieved

 

Return value

 

Value

Meaning

 

 

Empty string

The value of the nDriveIndex parameter was out of range. Use the value returned by the GetCdDrivesCount method in order to know how many CD drive are currently installed on the system.

Valid string

The string containing the letter of the requested CD drive.