How to reference ownership of a goal created with with TEdit.Create(Self)
, and will it be used in another object that is also being created as with TSpeedButton.Create(Self)
?
Follow the code:
with TEdit.Create(Self) do
begin
Name := 'ed'+IntToStr(i);
Parent := Self;
Top := 0;
Left := 0;
Width := 50;
with TSpeedButton.Create(Self) do
begin
Name := 'sb'+IntToStr(i);
Parent := Self;
Top := 0;
//Left := TEdit().Left + TEdit().Width; //Como referenciar o TEdit?
Width := 20;
end;
end;