Share via


Commands.Raise (Método)

Actualización: noviembre 2007

Ejecuta el comando especificado.

Espacio de nombres:  EnvDTE
Ensamblado:  EnvDTE (en EnvDTE.dll)

Sintaxis

Sub Raise ( _
    Guid As String, _
    ID As Integer, _
    <OutAttribute> ByRef CustomIn As Object, _
    <OutAttribute> ByRef CustomOut As Object _
)

Dim instance As Commands
Dim Guid As String
Dim ID As Integer
Dim CustomIn As Object
Dim CustomOut As Object

instance.Raise(Guid, ID, CustomIn, CustomOut)
void Raise(
    string Guid,
    int ID,
    out Object CustomIn,
    out Object CustomOut
)
void Raise(
    [InAttribute] String^ Guid, 
    [InAttribute] int ID, 
    [InAttribute] [OutAttribute] Object^% CustomIn, 
    [InAttribute] [OutAttribute] Object^% CustomOut
)
function Raise(
    Guid : String, 
    ID : int, 
    CustomIn : Object, 
    CustomOut : Object
)

Parámetros

  • ID
    Tipo: System.Int32

    Necesario. Identificador del comando.

  • CustomIn
    Tipo: System.Object%

    Necesario. Argumentos de un valor SafeArray recibido del objeto OLECommandTarget.

  • CustomOut
    Tipo: System.Object%

    Necesario. Argumentos de un valor SafeArray enviado que devuelve el objeto OLECommandTarget.

Ejemplos

' Macro code.
Sub RaiseExample()
   ' Before running, you must add a reference to the Office 
   ' typelib to gain access to the CommandBar object.
   Dim cmds As Commands
   Dim cmdobj As Command
   Dim customin, customout As Object
   Dim colAddins As AddIns

   ' Set references.
   colAddins = DTE.AddIns()
   cmds = DTE.Commands
   cmdobj = cmds.Item("File.NewFile")

   ' Execute the File.NewFile command.
   cmds.Raise(cmdobj.Guid, cmdobj.ID, customin, customout)
End Sub

Permisos

Vea también

Referencia

Commands (Interfaz)

Commands (Miembros)

EnvDTE (Espacio de nombres)