Stupid isnt it ? I tend to set the parent to the owner inside my
component.creates.
To: Multiple recipients of list delphi <[EMAIL PROTECTED]>
Send reply to: [EMAIL PROTECTED]
From: "David Brennan" <[EMAIL PROTECTED]>
Subject: Re: [DUG]: Control inside a Panel
Date sent: Tue, 31 Oct 2000 12:08:13 +1300
> By default a new control doesn't have a parent. Add the following line:
>
> Planner.Parent := Self;
>
> Cheers,
> David.
> DB Solutions.
>
> > Hi all.
> >
> > I have just created a component subclassed of a TPanel.
> >
> > I am trying to create another control inside the TPanel like so......
> >
> > ************
> > constructor TCustomPanel2.Create(aOwner:TPanel);
> > begin
> > inherited create(AOwner);
> >
> > Planner := TPegPlanner.create(Self);
> >
> > Planner.left:=10;
> > Planner.top:=10;
> > Planner.width:=150;
> > planner.height:=150;
> > Planner.visible:=true;
> > end;
> > ************
> >
> > BUT the control does not appear ontop of the TPanel. Can anyone see why
> ???
> >
> > Cjeers, Jeremy Coulter
> >
>
> ---------------------------------------------------------------------------
> New Zealand Delphi Users group - Delphi List - [EMAIL PROTECTED]
> Website: http://www.delphi.org.nz
> To UnSub, send email to: [EMAIL PROTECTED]
> with body of "unsubscribe delphi"
>
Rohit
======================================================================
CFL - Computer Fanatics Ltd. 21 Barry's Point Road, AKL, New Zealand
PH (649) 489-2280
FX (649) 489-2290
email [EMAIL PROTECTED] or [EMAIL PROTECTED]
======================================================================
---------------------------------------------------------------------------
New Zealand Delphi Users group - Delphi List - [EMAIL PROTECTED]
Website: http://www.delphi.org.nz
To UnSub, send email to: [EMAIL PROTECTED]
with body of "unsubscribe delphi"