Was this page helpful?
Your feedback about this content is important. Let us know what you think.
Additional feedback?
1500 characters remaining
Export (0) Print
Expand All

Sys.Application.addComponent Method

.NET Framework 3.5

Registers a component with the application and initializes it if the component is not already initialized. This member is static and can be invoked without creating an instance of the class.

Sys.Application.addComponent(component);

component

An instance of a type derived from the Component class to register with the client application.

Exception type

Condition

Error.invalidOperation Function

(Debug) component does not contain a valid ID.

Use the addComponent function to register a component with the application and to initialize it if the component is not already initialized.

Registering a component with the application also enables you to get a reference to the component or to verify that it exists. By using the Sys.Application.findComponent method of the Sys.Application class or the $find shortcut method, you can search for registered components in the application or in any subcomponent hierarchy.

Community Additions

ADD
Show:
© 2015 Microsoft