Windows Mobile 6.5
A version of this page is also available for

This method creates an object that can be used to enumerate the current advisory connections.

HRESULT EnumDAdvise(
  IEnumSTATDATA** ppenumAdvise


[out] Address of the IEnumSTATDATA* pointer variable that receives the interface pointer to the new enumerator object.

If the implementation sets *ppenumAdvise to NULL, there are no connections to advise sinks at this time.

This method supports the standard return value E_OUTOFMEMORY.

If the enumerator object is successfully instantiated or there are no connections, the method returns S_OK.

If the advisory notifications are not supported by this object, OLE_E_ADVISENOTSUPPORTED is returned.

The enumerator object created by this method implements the IEnumSTATDATA interface, which is one of the standard enumerator interfaces that contain the Next, Reset,Clone, and Skip methods.

IEnumSTATDATA permits the enumeration of the data stored in an array of STATDATA structures.

Each of these structures provides information on a single advisory connection and includes FORMATETC and ADVF information, as well as the pointer to the advise sink and the token representing the connection.

To determine whether the platform supports this interface, see Determining Supported COM APIs.

After getting a pointer through this method, the data object can call the appropriate enumeration methods. While the enumeration is in progress, the effect of adding more advisory connections on the subsequent enumeration is undefined.

Headerobjidl.h, objidl.idl
Libraryole32.lib, uuid.lib
Windows Embedded CEWindows CE 3.0 and later
Windows MobileWindows Mobile Version 5.0 and later

Community Additions