ITextStoreAnchor::AdviseSink method (textstor.h)
The ITextStoreAnchor::AdviseSink method installs a new advise sink from the ITextStoreAnchorSink interface or modifies an existing advise sink.
HRESULT AdviseSink( REFIID riid, IUnknown *punk, DWORD dwMask );
Specifies the sink interface. The only supported value is IID_ITextStoreAnchorSink.
Pointer to the sink interface to advise. Cannot be NULL.
Specifies the events that notify the advise sink. For more information about possible parameter values, see TS_AS_* Constants.
This method can return one of these values.
||The method was successful.|
||The specified sink interface riid could not be obtained.|
||The specified sink interface is unsupported.|
||The specified sink object could not be obtained.|
Subsequent calls with the same interface, represented by the punk parameter, are handled as requests to update the dwMask parameter. Servers should not call the AddRef method on the sink in response to such a request.
Servers only maintain a single connection point. Attempts to advise a second sink object fail until the original sink object is removed. Applications should use the ITextStoreAnchor::UnadviseSink method to unregister the sink object when notifications are not required.
|Minimum supported client||Windows 2000 Professional [desktop apps | UWP apps]|
|Minimum supported server||Windows 2000 Server [desktop apps | UWP apps]|
|Redistributable||TSF 1.0 on Windows 2000 Professional|