hey, so it sounds like your trying to make a compound
component. When you create them and they are visible
components you have to set the Parent after you create
it.
Instead of using a CustomEdit as your base class you
might want to use TWinControl and create both your
Edit & Combo within that. It would make it a bit
easier to read.
type
TtwsEditCombo = class(TWinControl)
private
{ Private declarations }
FCombo: TComboBox;
FEdit: TEdit;
protected
{ Protected declarations }
public
{ Public declarations }
constructor Create(AOwner: TComponent); override;
destructor Destroy; override;
published
{ Published declarations }
property Combo: TComboBox read FCombo Write
FCombo;
property Edit: TEdit read FEdit Write FEdit;
property OnDockDrop;
property OnDockOver;
property OnEnter;
property OnExit;
property OnGetSiteInfo;
property OnKeyDown;
property OnKeyPress;
property OnKeyUp;
property OnUnDock;
end;
implementation
constructor TtwsEditCombo.Create(AOwner: TComponent);
begin
inherited Create(AOwner);
{ ToDo : Add your initialization code here. }
{ TCombo }
FCombo:= TComboBox.Create(self);
FCombo.Parent := self;
with FCombo do begin
{ set default values }
visible := false;
end;
{ TEdit }
FEdit:= TEdit.Create(self);
FEdit.Parent := self;
with FEdit do begin
{ set default values }
visible := true;
end;
end; { Create }
destructor TtwsEditCombo.Destroy;
begin
FCombo.Free;
FEdit.Free;
inherited Destroy;
end; { Destroy }
__________________________________________________
Do You Yahoo!?
Tired of spam? Yahoo! Mail has the best spam protection around
http://mail.yahoo.com
------------------------ Yahoo! Groups Sponsor --------------------~-->
Fair play? Video games influencing politics. Click and talk back!
http://us.click.yahoo.com/T8sf5C/tzNLAA/TtwFAA/i7folB/TM
--------------------------------------------------------------------~->
-----------------------------------------------------
Home page: http://groups.yahoo.com/group/delphi-en/
To unsubscribe: [EMAIL PROTECTED]
Yahoo! Groups Links
<*> To visit your group on the web, go to:
http://groups.yahoo.com/group/delphi-en/
<*> To unsubscribe from this group, send an email to:
[EMAIL PROTECTED]
<*> Your use of Yahoo! Groups is subject to:
http://docs.yahoo.com/info/terms/