EComponentError = class(Exception);
class PASCALIMPLEMENTATION EComponentError : public System::Sysutils::Exception
EComponentError is the exception class for registering and renaming components.
EComponentError is raised when:
- An attempt to register a component fails.
- An application cannot rename a component.
- (Windows-only) A request is made to retrieve the COM interface of a component that does not support COM.
To register a component, write a procedure called "Register", declared in the interface section (Delphi) or namespace (C++) of the component's unit file. Note that unlike most Delphi procedure names, the name of the Register procedure is case-sensitive. Register must call RegisterComponents for each component you want to register.
Failure to rename a component occurs when an application tries to rename the component at run time, and the new name is the same as the name of another component with the same Owner, or is not a valid identifier.