Proprietà AddIn.Collection

Restituisce l'insieme contenente l'oggetto AddIn che supporta la proprietà.

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

Sintassi

'Dichiarazione
ReadOnly Property Collection As AddIns
    Get
AddIns Collection { get; }
property AddIns^ Collection {
    AddIns^ get ();
}
abstract Collection : AddIns
function get Collection () : AddIns

Valore proprietà

Tipo: EnvDTE.AddIns
Insieme di AddIns.

Esempi

public void AddinCollExample(AddIn addIn)
{
   // For this example to work, there should be an add-in
   // available in the Visual Studio enviroment.
   
   string peers = "";
   
   // Retrieve all peer elements of the addin
   foreach (AddIn someAddin in addIn.Collection)
   {
      if ((someAddin != addIn) && (someAddin.Name != null))
         peers += someAddin.Name + "\n";
   }
   MessageBox.Show(addIn.Name + " has the following peer elements:\n\n" + peers);
}

Sicurezza di .NET Framework

Vedere anche

Riferimenti

AddIn Interfaccia

Spazio dei nomi EnvDTE

Altre risorse

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