Enables clients to receive notification when the Dynamic Help window is about to update based on the active context.
Assembly: Microsoft.VisualStudio.Shell.Interop (in Microsoft.VisualStudio.Shell.Interop.dll)
‘선언 Function AdviseUpdate ( _ pUpdate As IVsUserContextUpdate, _ <OutAttribute> ByRef pdwCookie As UInteger _ ) As Integer ‘사용 방법 Dim instance As IVsUserContext Dim pUpdate As IVsUserContextUpdate Dim pdwCookie As UInteger Dim returnValue As Integer returnValue = instance.AdviseUpdate(pUpdate, _ pdwCookie)
int AdviseUpdate( IVsUserContextUpdate pUpdate, out uint pdwCookie )
int AdviseUpdate( [InAttribute] IVsUserContextUpdate^ pUpdate, [OutAttribute] unsigned int% pdwCookie )
abstract AdviseUpdate : pUpdate:IVsUserContextUpdate * pdwCookie:uint32 byref -> int
function AdviseUpdate( pUpdate : IVsUserContextUpdate, pdwCookie : uint ) : int
[in] Pointer to the IVsUserContextUpdate interface, which sends an update notification.
[out, retval] Unique identifier for the referenced event sink. This value is required to unadvise the event sink using UnadviseUpdate.
HRESULT IVsUserContext::AdviseUpdate( [in] IVsUserContextUpdate * pUpdate, [out, retval] VSCOOKIE * pdwCookie );
When you create a context bag on an editor, call IVsUserContext.AdviseUpdate and pass along a pointer to your context provider. When Update is called internally by the environment, the Dynamic Help window goes through each context bag in the active selection synchronously and retrieves context from any context bag and associated subcontext bag that is flagged as dirty using the SetDirty method. However, if the context bag is on an editor window that has called IVsUserContext::AdviseUpdate and has also implemented the IVsUserContextUpdate interface, then the environment calls UpdateUserContext to inform the context provider that the context bag will be updated (that is, Update will be called). You can use this call to change the attributes and keywords in the context bag before the Dynamic Help window update occurs. For more information, see Providing Context for an Editors and Designers.
To disable notification of user context updates, call UnadviseUpdate.
.NET Framework Security
- Full trust for the immediate caller. This member cannot be used by partially trusted code. For more information, see Using Libraries from Partially Trusted Code.