控件数据

var
  chboxs: array of TCheckBox;
  i: integer;
begin
   setlength(Chboxs,10);
   for i:=0 to 9 do
   begin
      Chboxs[i]:=TCheckBox.create(self);
      Chboxs[i].left:=10;
      Chboxs[i].top:=100+20*i;
      chboxs[i].caption:='hehe'+inttostr(i);
      chboxs[i].Parent:=self;
   end;
end;
这样在后面处理控件时用这个数据比较方便,
如果你作成死的,你就必须一个一个来,而不能统一用数据作。
呵呵,我以前也用foxpro,可惜delphi中没有宏替换函数,让人很失望,不过很快你就会适应了