次の方法で共有


IVsCfgProvider2.AdviseCfgProviderEvents Method

Registers the caller for configuration event notification.

Namespace:  Microsoft.VisualStudio.Shell.Interop
Assembly:  Microsoft.VisualStudio.Shell.Interop (in Microsoft.VisualStudio.Shell.Interop.dll)

Syntax

'宣言
Function AdviseCfgProviderEvents ( _
    pCPE As IVsCfgProviderEvents, _
    <OutAttribute> ByRef pdwCookie As UInteger _
) As Integer
'使用
Dim instance As IVsCfgProvider2
Dim pCPE As IVsCfgProviderEvents
Dim pdwCookie As UInteger
Dim returnValue As Integer

returnValue = instance.AdviseCfgProviderEvents(pCPE, _
    pdwCookie)
int AdviseCfgProviderEvents(
    IVsCfgProviderEvents pCPE,
    out uint pdwCookie
)
int AdviseCfgProviderEvents(
    [InAttribute] IVsCfgProviderEvents^ pCPE, 
    [OutAttribute] unsigned int% pdwCookie
)
function AdviseCfgProviderEvents(
    pCPE : IVsCfgProviderEvents, 
    pdwCookie : uint
) : int

Parameters

  • pdwCookie
    Type: System.UInt32%

    [out] Pointer to a token representing the completed registration.

Return Value

Type: System.Int32

If the method succeeds, it returns S_OK. If it fails, it returns an error code.

Remarks

COM Signature

From vsshell.idl:

HRESULT IVsCfgProvider2::AdviseCfgProviderEvents(
   [in] IVsCfgProviderEvents *pCPE,
   [out] VSCOOKIE *pdwCookie
);

AdviseCfgProviderEvents is called by the environment. The environment implements the five methods of IVsCfgProviderEvents — one for each type of configuration event. For example, when a platform name is added, the project responsible for the change calls OnPlatformNameAdded.

Permissions

See Also

Reference

IVsCfgProvider2 Interface

IVsCfgProvider2 Members

Microsoft.VisualStudio.Shell.Interop Namespace