次の方法で共有


WindowPane.IOleCommandTarget.Exec Method

Executes the specified command.

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

Syntax

'宣言
Private Function Exec ( _
    ByRef guidGroup As Guid, _
    nCmdId As UInteger, _
    nCmdExcept As UInteger, _
    pIn As IntPtr, _
    vOut As IntPtr _
) As Integer Implements IOleCommandTarget.Exec
int IOleCommandTarget.Exec(
    ref Guid guidGroup,
    uint nCmdId,
    uint nCmdExcept,
    IntPtr pIn,
    IntPtr vOut
)

Parameters

  • guidGroup
    Type: System.Guid%
    The GUID of the command group to which the command belongs.
  • nCmdExcept
    Type: System.UInt32
    Values taken from the OLECMDEXECOPT enumeration, which describe how the object should execute the command.
  • pIn
    Type: System.IntPtr
    Pointer to a VARIANTARG structure that contains input arguments. Can be nulla null reference (Nothing in Visual Basic).
  • vOut
    Type: System.IntPtr
    Pointer to a VARIANTARG structure that contains command output. Can be nulla null reference (Nothing in Visual Basic).

Return Value

Type: System.Int32
Returns OLECMDERR_E_NOTSUPPORTED if the project manager is closed or the command is not supported. Otherwise, returns S_OK or an error code if one of the executed commands returned an error code.

Implements

IOleCommandTarget.Exec(Guid%, UInt32, UInt32, IntPtr, IntPtr)

Remarks

This method is called by Visual Studio when the user has asked to execute a particular command. There is no need to override this method. If you need to get menu commands, you must use IMenuCommandService.

.NET Framework Security

See Also

Reference

WindowPane Class

Microsoft.VisualStudio.Shell Namespace