Identifies whether the component is a subcomponent.
procedure SetSubComponent(IsSubComponent: Boolean);
__fastcall SetSubComponent(Boolean IsSubComponent);
Call SetSubComponent to indicate that this component is or is not a subcomponent. A subcomponent is a component whose Owner is a component other than the form or data module in which it resides. Unless such a component calls SetSubComponent with IsSubComponent set to true, its published properties will not be saved to the form file.
IsSubComponent indicates whether the component is a subcomponent (true) or not (false).
SetSubComponent is called at design time either
From the constructor of a component that always acts as a subcomponent. In this case, the component calls its own SetSubComponent method from the constructor with IsSubComponent set to true.
Immediately after constructing an instance of the subcomponent. In this case, the Owner calls the SetSubComponent method of a component it has just instantiated, with IsSubComponent set to true.
Copyright(C) 2009 Embarcadero Technologies, Inc. All Rights Reserved.
What do you think about this topic? Send feedback!