Index   Commented   Search   About

IOleAdviseHolder::EnumAdvise

Enumerates the advisory connections currently established for an object.

HRESULT EnumAdvise(

IEnumSTATDATA ** ppenumAdvise
//A pointer to a pointer to the new enumerator
);

Parameter

ppenumAdvise

[out] Points to where the new enumerator should be returned. NULL is a legal return value indicating that there are presently no advisory connections on the object. If an error is returned; this parameter must be set to NULL. Each time an OLE advise holder receives a call to IOleAdviseHolder::EnumAdvise; it must increase the reference count on the pointer it returns. It is the caller's responsibility to call IUnknown::Release when it is done with the pointer.

Return Values

S_OK

Enumerator returned successfully.

E_FAIL

Enumerator could not be returned.

E_NOTIMPL

EnumAdvise is not implemented.

Comments

While an enumeration is in progress; the effect of registering or revoking advisory connections on what is to be enumerated is undefined. The returned enumerator is of type IEnumSTATDATA. It enumerates items of type STATDATA; which are defined as follows:

typedef struct tagSTATDATA {

FORMATETC Formatetc;

DWORD grfAdvf;

IAdviseSink * pAdvise;

DWORD dwConnection;

}STATDATA;

See Also

IOleAdviseHolder::Advise, IOleAdviseHolder::UnAdvise, IOleObject::EnumAdvise

Related Links

Software for Delphi and C++ Builder developers
Software for Visual Studio .NET developers
Software for Visual Basic 6 developers
Delphi Tips&Tricks
MegaDetailed.NET
TMS Scripter Studio Pro components for Delphi/C++Builder

More Online Helps

Win32 Programmer's Reference (win32.hlp)
Win32 Multimedia Programmer's Reference (mmedia.hlp)
Microsoft Windows Pen API Programmer's Reference (penapi.hlp)
Microsoft Windows Sockets 2 Reference (sock2.hlp)
Microsoft Windows Telephony API (TAPI) Programmer's Reference (sock2.hlp)
Unix Manual Pages

Free Tech Secrets ;) Copyright © 2008 Free Tect Secrets ;) greatis just4fun network just4fun