Ver Mensaje Individual
  #3  
Antiguo 30-06-2006
metalfox6383 metalfox6383 is offline
Miembro
 
Registrado: jul 2005
Posts: 97
Reputación: 21
metalfox6383 Va por buen camino
Question

Ok.

Tfm_Principal = class(TForm)
procedure FormCreate(Sender: TObject);
private
//declaro la matriz.
mt_NumeroA: array of TLabel;
public
{ Public declarations }
end;

var
fm_Principal: Tfm_Principal;

implementation
{$R *.dfm}

procedure Tfm_Principal.FormCreate(Sender: TObject);
var conteo: byte;
begin
//creo los objetos.
setlength(mt_NumeroA,7);
for conteo:=0 to 7 do begin
mt_NumeroA[conteo]:= TLabel.Create(nil);
mt_NumeroA[conteo].Parent:=fm_Principal;
mt_NumeroA[conteo].Caption:=inttostr(conteo);
mt_NumeroA[conteo].Left:=5;
mt_NumeroA[conteo].Top:=15+15*conteo;
end;
end;
end.

No sé cómo debo destruirlos. He destruido otros objetos, pero nunca intenté con matrices.
Responder Con Cita