ComponentEventArgs Classe

Definizione

public ref class ComponentEventArgs : EventArgs
[System.Runtime.InteropServices.ComVisible(true)]
public class ComponentEventArgs : EventArgs
public class ComponentEventArgs : EventArgs
[<System.Runtime.InteropServices.ComVisible(true)>]
type ComponentEventArgs = class
    inherit EventArgs
type ComponentEventArgs = class
    inherit EventArgs
Public Class ComponentEventArgs
Inherits EventArgs
Ereditarietà
ComponentEventArgs
Attributi

Esempio

Nell'esempio seguente viene illustrata la creazione di un oggetto ComponentEventArgs.

public:
   // This example method creates a ComponentEventArgs using the specified argument.
   // Typically, this type of event args is created by a design mode subsystem.
   ComponentEventArgs^ CreateComponentEventArgs( IComponent^ component )
   {
      // The component that is related to the event:  args.Component
      return gcnew ComponentEventArgs( component );
   }
// This example method creates a ComponentEventArgs using the specified argument.
// Typically, this type of event args is created by a design mode subsystem.  
public ComponentEventArgs CreateComponentEventArgs(IComponent component)
{
    ComponentEventArgs args = new ComponentEventArgs(component);

    // The component that is related to the event:  args.Component

    return args;
}
' This example method creates a ComponentEventArgs using the specified argument.
' Typically, this type of event args is created by a design mode subsystem.  
Public Function CreateComponentEventArgs(ByVal component As IComponent) As ComponentEventArgs

    Dim args As New ComponentEventArgs(component)

    ' The component that is related to the event:  args.Component

    Return args
End Function

Commenti

ComponentEventArgs è la classe di argomenti dell'evento radice per tutti gli eventi di gestione dei componenti. Questo tipo di evento si verifica quando si aggiungono o rimuovono componenti tramite una finestra di progettazione.

Costruttori

Nome Descrizione
ComponentEventArgs(IComponent)

Inizializza una nuova istanza della classe ComponentEventArgs.

Proprietà

Nome Descrizione
Component

Ottiene il componente associato all'evento.

Metodi

Nome Descrizione
Equals(Object)

Determina se l'oggetto specificato è uguale all'oggetto corrente.

(Ereditato da Object)
GetHashCode()

Funge da funzione hash predefinita.

(Ereditato da Object)
GetType()

Ottiene il Type dell'istanza corrente.

(Ereditato da Object)
MemberwiseClone()

Crea una copia superficiale del Objectcorrente.

(Ereditato da Object)
ToString()

Restituisce una stringa che rappresenta l'oggetto corrente.

(Ereditato da Object)

Si applica a

Vedi anche