IVsMonitorSelection.SetCmdUIContext Method
Sets the state of the command UI context to active or inactive.
Namespace: Microsoft.VisualStudio.Shell.Interop
Assembly: Microsoft.VisualStudio.Shell.Interop (in Microsoft.VisualStudio.Shell.Interop.dll)
Syntax
'Déclaration
Function SetCmdUIContext ( _
dwCmdUICookie As UInteger, _
fActive As Integer _
) As Integer
'Utilisation
Dim instance As IVsMonitorSelection
Dim dwCmdUICookie As UInteger
Dim fActive As Integer
Dim returnValue As Integer
returnValue = instance.SetCmdUIContext(dwCmdUICookie, _
fActive)
int SetCmdUIContext(
uint dwCmdUICookie,
int fActive
)
int SetCmdUIContext(
[InAttribute] unsigned int dwCmdUICookie,
[InAttribute] int fActive
)
abstract SetCmdUIContext :
dwCmdUICookie:uint32 *
fActive:int -> int
function SetCmdUIContext(
dwCmdUICookie : uint,
fActive : int
) : int
Parameters
- dwCmdUICookie
Type: System.UInt32
[in] DWORD representation of the GUID identifying the command UI context passed as the rguidCmdUI parameter in the call to GetCmdUIContextCookie.
- fActive
Type: System.Int32
[out] Flag that is set to true if the command UI context should be set to active and false if it should be set to inactive.
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 IVsMonitorSelection::SetCmdUIContext(
[in] VSCOOKIE dwCmdUICookie,
[in] BOOL fActive
);
.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.