AddIns.Parent Property

Gets the immediate parent object of a AddIns collection.

Namespace:  EnvDTE
Assembly:  EnvDTE (in EnvDTE.dll)

Syntax

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

Property Value

Type: System.Object
The immediate parent object of a given object.

Remarks

The Parent property returns the immediate parent to the AddIns collection.

Examples

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

.NET Framework Security

See Also

Reference

AddIns Interface

EnvDTE Namespace

Other Resources

How to: Compile and Run the Automation Object Model Code Examples