IWMDMEnumStorage::Next
The Next method retrieves a pointer to the next IWMDMStorage or IWMDMDevice interface.
Syntax
HRESULT Next(
ULONG celt,
IWMDMStorage** ppStorage,
ULONG* pceltFetched
);
Parameters
celt
[in] Number of storages requested.
ppStorage
[out] Pointer to a storage device.
pceltFetched
[out] Number of storage devices enumerated.
Return Values
The method returns an HRESULT. All the interface methods in Windows Media Device Manager and service provider can return any of the following classes of error codes:
- Standard COM error codes
- Windows error codes converted to HRESULT values
- Windows Media Device Manager error codes
For a complete list of possible error codes, see Error Codes.
Possible values include, but are not limited to, those in the following table.
Return code | Description |
S_OK | The method succeeded. |
S_FALSE | No more storage devices exist. |
E_INVALIDARG | A parameter is invalid or is a NULL pointer. |
E_FAIL | An unspecified error occurred. |
Remarks
Windows Media Device Manager delegates the storage enumeration to the corresponding service provider. For information on service provider storage enumeration, see the IMDSPEnumStorage interface.
The storage enumerator may not reflect the effect of media insertion and removal. In that case, the application should obtain a new storage enumerator object by calling IWMDMDevice::EnumStorage to get the refreshed list.
Requirements
Header: Defined in wmdm.idl.
Library: mssachlp.lib
See Also