ComponentRenameEventArgs Classe
Definizione
Importante
Alcune informazioni sono relative alla release non definitiva del prodotto, che potrebbe subire modifiche significative prima della release definitiva. Microsoft non riconosce alcuna garanzia, espressa o implicita, in merito alle informazioni qui fornite.
Fornisce i dati per l'evento ComponentRename.
public ref class ComponentRenameEventArgs : EventArgs
public class ComponentRenameEventArgs : EventArgs
[System.Runtime.InteropServices.ComVisible(true)]
public class ComponentRenameEventArgs : EventArgs
type ComponentRenameEventArgs = class
inherit EventArgs
[<System.Runtime.InteropServices.ComVisible(true)>]
type ComponentRenameEventArgs = class
inherit EventArgs
Public Class ComponentRenameEventArgs
Inherits EventArgs
- Ereditarietà
- Attributi
Esempio
Nell'esempio seguente viene illustrata la creazione di un oggetto ComponentRenameEventArgs.
public:
// This example method creates a ComponentRenameEventArgs using the specified arguments.
// Typically, this type of event args is created by a design mode subsystem.
ComponentRenameEventArgs^ CreateComponentRenameEventArgs( Object^ component, String^ oldName, String^ newName )
{
// The component that was renamed: args.Component
// The previous name of the component: args.OldName
// The new name of the component: args.NewName
return gcnew ComponentRenameEventArgs( component, oldName, newName );
}
// This example method creates a ComponentRenameEventArgs using the specified arguments.
// Typically, this type of event args is created by a design mode subsystem.
public ComponentRenameEventArgs CreateComponentRenameEventArgs(object component, string oldName, string newName)
{
ComponentRenameEventArgs args = new ComponentRenameEventArgs(component, oldName, newName);
// The component that was renamed: args.Component
// The previous name of the component: args.OldName
// The new name of the component: args.NewName
return args;
}
' This example method creates a ComponentRenameEventArgs using the specified arguments.
' Typically, this type of event args is created by a design mode subsystem.
Public Function CreateComponentRenameEventArgs(ByVal component As Object, ByVal oldName As String, ByVal newName As String) As ComponentRenameEventArgs
Dim args As New ComponentRenameEventArgs(component, oldName, newName)
' The component that was renamed: args.Component
' The previous name of the component: args.OldName
' The new name of the component: args.NewName
Return args
End Function
Commenti
Un ComponentRenameEventArgs oggetto fornisce i dati relativi a un ComponentRename evento.
Un ComponentRenameEventArgs oggetto fornisce le informazioni seguenti:
Proprietà Component che fa riferimento al componente da rinominare.
Proprietà OldName che indica il nome precedente del componente.
Proprietà NewName che indica il nuovo nome del componente.
Costruttori
| ComponentRenameEventArgs(Object, String, String) |
Inizializza una nuova istanza della classe ComponentRenameEventArgs. |
Proprietà
| Component |
Ottiene il componente che viene rinominato. |
| NewName |
Ottiene il nome del componente dopo l'evento di ridenominazione. |
| OldName |
Ottiene il nome del componente prima dell'evento di ridenominazione. |
Metodi
| 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 l'oggetto Type dell'istanza corrente. (Ereditato da Object) |
| MemberwiseClone() |
Crea una copia superficiale dell'oggetto Object corrente. (Ereditato da Object) |
| ToString() |
Restituisce una stringa che rappresenta l'oggetto corrente. (Ereditato da Object) |