Previous Next

SetupDiGetClassDescriptionEx

The SetupDiGetClassDescriptionEx function retrieves the description of a setup class installed on a local or remote machine.

WINSETUPAPI BOOL WINAPI
  SetupDiGetClassDescriptionEx(
    IN LPGUID  ClassGuid,
    OUT PTSTR  ClassDescription,
    IN DWORD  ClassDescriptionSize,
    OUT PDWORD  RequiredSize,  OPTIONAL
    IN PCTSTR  MachineName,  OPTIONAL
    IN PVOID  Reserved
    );

Parameters

ClassGuid
Supplies the GUID of the setup class whose description is to be retrieved.
ClassDescription
Supplies a pointer to a character buffer that receives the class description.
ClassDescriptionSize
Supplies the size, in characters, of the ClassDescription buffer.
RequiredSize
Receives the size, in characters, required to store the class description (including terminating NULL). RequiredSize is always less than LINE_LEN.
MachineName
Optionally supplies the name of a remote machine on which the setup class resides. A value of NULL for MachineName specifies that the class is installed on the local machine.
Reserved
Must be NULL.

Return Value

The function returns TRUE if it is successful. Otherwise, it returns FALSE and the logged error can be retrieved with a call to GetLastError.

Headers

Declared in setupapi.h. Include setupapi.h.

Comments

If there is a friendly name in the registry key for the class, this routine returns the friendly name. Otherwise, this routine returns the class name.

See Also

SetupDiBuildClassInfoList, SetupDiBuildClassInfoListEx, SetupDiGetDeviceInfoListDetail, SetupDiGetINFClass