Condividi tramite


Proprietà AddIns.Parent

Ottiene il primo oggetto padre di una raccolta AddIns.

Spazio dei nomi:  EnvDTE
Assembly:  EnvDTE (in EnvDTE.dll)

Sintassi

'Dichiarazione
ReadOnly Property Parent As Object
Object Parent { get; }
property Object^ Parent {
    Object^ get ();
}
abstract Parent : Object with get
function get Parent () : Object

Valore proprietà

Tipo: Object
Primo oggetto padre di un determinato oggetto.

Note

La proprietà Parent restituisce il primo oggetto padre della raccolta AddIns.

Esempi

public void Example(DTE2 dte)
{
   try
   {
      DTE2 dteexample = (DTE2)dte.AddIns.Parent;
      MessageBox.Show(dteexample.FullName);
   }
   catch (Exception ex)
   {
      MessageBox.Show(ex.Message);
   }
}

Sicurezza di .NET Framework

Vedere anche

Riferimenti

AddIns Interfaccia

Spazio dei nomi EnvDTE

Altre risorse

Procedura: compilare ed eseguire gli esempi di codice del modello a oggetti di automazione