Queries for the command status on the selected nodes.
Namespace: Microsoft.VisualStudio.Package
Assembly: MPF.Project.NonShipping (in MPF.Project.NonShipping.dll)
Syntax
'宣言
Protected Overridable Function QueryStatusSelection ( _
guidCmdGroup As Guid, _
cCmds As UInteger, _
prgCmds As OLECMD(), _
pCmdText As IntPtr, _
commandOrigin As CommandOrigin _
) As Integer
'使用
Dim guidCmdGroup As Guid
Dim cCmds As UInteger
Dim prgCmds As OLECMD()
Dim pCmdText As IntPtr
Dim commandOrigin As CommandOrigin
Dim returnValue As Integer
returnValue = Me.QueryStatusSelection(guidCmdGroup, _
cCmds, prgCmds, pCmdText, commandOrigin)
protected virtual int QueryStatusSelection(
Guid guidCmdGroup,
uint cCmds,
OLECMD[] prgCmds,
IntPtr pCmdText,
CommandOrigin commandOrigin
)
protected:
virtual int QueryStatusSelection(
Guid guidCmdGroup,
unsigned int cCmds,
array<OLECMD>^ prgCmds,
IntPtr pCmdText,
CommandOrigin commandOrigin
)
protected function QueryStatusSelection(
guidCmdGroup : Guid,
cCmds : uint,
prgCmds : OLECMD[],
pCmdText : IntPtr,
commandOrigin : CommandOrigin
) : int
Parameters
guidCmdGroup
Type: System.GuidThe GUID of the command group.
cCmds
Type: System.UInt32The number of commands in the command array.
prgCmds
Type: []The array of commands to apply.
pCmdText
Type: System.IntPtrPointer to a structure that contains name and/or status information.
commandOrigin
Type: Microsoft.VisualStudio.Package.CommandOriginThe CommandOrigin value. Can be either UiHierarchy or OleCommandTarget.
Return Value
Type: System.Int32
If the program manager is null or closed, or the command is not supported, returns OLECMDERR_E_NOTSUPPORTED(). If the GUID of the command group is empty, returns OLECMDERR_E_UNKNOWNGROUP(). Otherwise, returns S_OK.
Permissions
- 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.