Crear un componente en runtime (mientras el programa esta en marcha)
0000-00-00 00:00:00
procedure TForm1.miClick(Sender: TObject);
begin
ShowMessage('El nuevo boton ha sido pulsado');
end;
procedure TForm1.Button1Click(Sender: TObject);
begin
with TButton.Create(self) do begin
Left := 50;
Top := 50;
Width := 120;
Height := 40;
Name := 'Boton nuevo';
Caption := 'Un boton';
OnClick := miClick;
Parent := Form1;
end;
end;