GeppoDarkson
Programmer
Hi to all,
I have to make a new component based on a TPanel with some controls over it.
I need to know the Width and Height to set the position of the child controls (for example, a label in the middle of the panel).
When the component is creating I can't find how to know the "final" width (it gives me 185 as when you put it on the form with no drag).
If I call my method "ArrangeAllTheChildControls" at runtime it works.
I can't override OnShow, OnActivate etc to make the call.
I think that a Timer can handle this by activating the procedure after the creation, but it seems to be not so elegant, so maybe there are some better ways.
Any suggestions?
Thank you,
Ciao,
Geppo Darkson.
I have to make a new component based on a TPanel with some controls over it.
I need to know the Width and Height to set the position of the child controls (for example, a label in the middle of the panel).
When the component is creating I can't find how to know the "final" width (it gives me 185 as when you put it on the form with no drag).
If I call my method "ArrangeAllTheChildControls" at runtime it works.
I can't override OnShow, OnActivate etc to make the call.
I think that a Timer can handle this by activating the procedure after the creation, but it seems to be not so elegant, so maybe there are some better ways.
Any suggestions?
Thank you,
Ciao,
Geppo Darkson.