Platform SDK: Hardware |
The SetupDiEnumDeviceInterfaces function retrieves a context structure for a device interface of a device information set. Each call returns information about one device interface. The function can be called repeatedly to get information about several interfaces exposed by one or more devices.
BOOL SetupDiEnumDeviceInterfaces( HDEVINFO DeviceInfoSet, PSP_DEVINFO_DATA DeviceInfoData, CONST LPGUID InterfaceClassGuid, DWORD MemberIndex, PSP_DEVICE_INTERFACE_DATA DeviceInterfaceData );
If the DeviceInfoData parameter specifies a particular device, MemberIndex applies only to the interfaces exposed by that device.
If the function succeeds, the return value is nonzero.
If the function fails, the return value is zero. To get extended error information, call GetLastError.
The DeviceInterfaceData member is a pointer to a structure that identifies a requested device interface. To get detailed information about an interface, call the SetupDiGetDeviceInterfaceDetail function. The detailed information includes the name of the device interface that can be passed to a function (such as CreateFile) to get a handle to the interface.
Windows NT/2000: Requires Windows 2000.
Windows 95/98: Requires Windows 98.
Header: Declared in Setupapi.h.
Library: Use Setupapi.lib.
Device Management Overview, Device Management Functions, SetupDiGetClassDevs, SetupDiGetClassDevsEx, SetupDiGetDeviceInterfaceDetail, SP_DEVICE_INTERFACE_DATA, SP_DEVINFO_DATA