Show: Delphi C++
Display Preferences

System.Classes.TComponent.ValidateRename

From RAD Studio API Documentation
Jump to: navigation, search

Delphi

procedure ValidateRename(AComponent: TComponent; const CurName, NewName: string); virtual;

C++

virtual void __fastcall ValidateRename(TComponent* AComponent, const System::UnicodeString CurName, const System::UnicodeString NewName);

Properties

Type Visibility Source Unit Parent
procedure
function
protected
System.Classes.pas
System.Classes.hpp
System.Classes TComponent

Description

Ensures that renaming an owned component does not create a name conflict.

ValidateRename checks whether a component can rename one of its owned components, passed in AComponent, from its current name (CurName) to the string passed in NewName. If AComponent is nil (Delphi) or NULL (C++) or NewName is already the name of a component in the Components list, ValidateRename raises an EComponentError exception.

ValidateRename is used internally when the Name property is modified. It is not necessary to call it directly.

See Also

Personal tools
In Other Languages
Previous Versions
Assistance