Important:
This is retired content. This content is outdated and is no longer being maintained. It is provided as a courtesy for individuals who are still using these technologies. This content may contain URLs that were valid when originally published, but now link to sites or pages that no longer exist.
A version of this page is also available for
4/8/2010

This method retrieves a specified number of items in the enumeration sequence.

Syntax

HRESULT Next(
  DWORD 
cItemsToFetch,
  CLSID* 
pCLSID,
  WCHAR** 
Names,
  DWORD* 
pcItemsFetched
);

Parameters

cItemsToFetch

Number of items to retrieve.

pCLSID

[out] Array of size cItemsToFetchthat is filled with the CLSIDs of the enumerated DMOs.

Names

[out] Array of size cItemsToFetchthat is filled with the friendly names of the enumerated DMOs.

pcItemsFetched

[out] Pointer to a variable that receives the actual number of items retrieved. This parameter can be NULL if cItemsToFetchequals 1.

Return Value

Returns an HRESULTvalue. Possible values include the following.

Value Description

S_FALSE

Retrieved fewer items than requested

S_OK

Retrieved the requested number of items

E_INVALIDARG

Invalid argument

E_OUTOFMEMORY

Insufficient memory

E_POINTER

NULL pointer argument

Remarks

If the method succeeds, the arrays given by the pCLSIDand Namesparameters are filled with CLSIDs and wide-character strings. The value of *pcItemsFetchedspecifies the number of items returned in these arrays.

The method returns S_OK if it retrieves the requested number of items; in other words, if * pcItemsFetchedequals cItemsToFetch. Otherwise, it returns S_FALSE or an error code.

The caller must free the memory allocated for each string returned in the Namesparameter using the CoTaskMemFreefunction.

Requirements

Header dmo.h
Library Dmoguid.lib
Windows Embedded CE Windows CE .NET 4.1 and later
Windows Mobile Windows Mobile Version 5.0 and later

See Also

Reference

IEnumDMO