Unit 'Controls' Package
[Overview][Constants][Types][Classes][Procedures and functions][Variables][Index] [#lcl]


Checks whether the specified class type is allowed as a child control.


Source position: controls.pp line 2122

protected function TWinControl.ChildClassAllowed(

  ChildClass: TClass

):Boolean; override;




Class type examined in the method.

Function result

True when ChildClass is allowed in Controls.


ChildClassAllowed is an overridden method in TWinControl used to determine if instances of the class type in ClassType are allowed as child controls. Returns True if the specified class type is allowed as a child control in the Controls property.

In TWinControl, the return value is True when ChildClass has been assigned (not Nil) and the class type is derived from TControl.

ChildClassAllowed does not call the inherited method which always returns False.

ChildClassAllowed is called from the CheckChildClassAllowed method in TControl.

See also



Provides indexed access to the child controls for the class instance.



Returns True if the class is allowed for child controls.



The control within which the control is shown.

CT Web help

CodeTyphon Studio