Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Question regarding ownership of a TComponent

Status
Not open for further replies.

OmniCog

Programmer
Jan 23, 2004
27
0
0
CA
I've have a pretty simple question that I can't seem to figure out.

In the following code, XMLDoc will be freed when AOwner is free'd correct?

{...}
TServiceList = class(TListBox, IServiceView)
private
protected
XMLDoc : TXMLDocument;
{...}

constructor TServiceList.Create(AOwner: TComponent);
begin
inherited;
{...}
XMLDoc := TXMLDocument.Create(AOwner);
{...}
end;
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top