FileNode.QueryStatusOnNode Method

Checks whether a given command is supported and enabled on the file node.

Namespace:  Microsoft.VisualStudio.Package
Assembly:  MPF.Project.NonShipping (in MPF.Project.NonShipping.dll)

Syntax

'宣言
Protected Overrides Function QueryStatusOnNode ( _
    guidCmdGroup As Guid, _
    cmd As UInteger, _
    pCmdText As IntPtr, _
    ByRef result As QueryStatusResult _
) As Integer
'使用
Dim guidCmdGroup As Guid
Dim cmd As UInteger
Dim pCmdText As IntPtr
Dim result As QueryStatusResult
Dim returnValue As Integer

returnValue = Me.QueryStatusOnNode(guidCmdGroup, _
    cmd, pCmdText, result)
protected override int QueryStatusOnNode(
    Guid guidCmdGroup,
    uint cmd,
    IntPtr pCmdText,
    ref QueryStatusResult result
)
protected:
virtual int QueryStatusOnNode(
    Guid guidCmdGroup, 
    unsigned int cmd, 
    IntPtr pCmdText, 
    QueryStatusResult% result
) override
protected override function QueryStatusOnNode(
    guidCmdGroup : Guid, 
    cmd : uint, 
    pCmdText : IntPtr, 
    result : QueryStatusResult
) : int

Parameters

  • guidCmdGroup
    Type: System.Guid

    The GUID of the command group, a null reference (Nothing in Visual Basic) to specify the standard group.

  • pCmdText
    Type: System.IntPtr

    Pointer to a OLECMDTEXT structure that indicates the name and status information for a given command. Can be null.

Return Value

Type: System.Int32

Returns [F:Microsoft.VisualStudio.OLE.Interop OleConstants.OLECMDERR_E_UNKNOWNGROUP] if the command group is anything other than guidStandardCommandSet97() or guidStandardCommandSet2K(). Returns S_OK if the command was found, regardless of the status of the command.

Remarks

This method provides support for the following commands: Copy, Paste, Cut, Rename, ViewCode, Open, OpenWith, and.EXCLUDEFROMPROJECT. Override this method to support different commands.

Permissions

See Also

Concepts

IronPython Sample

Reference

FileNode Class

FileNode Members

Microsoft.VisualStudio.Package Namespace