程序执行到 TEdit(Assigned(FindComponent(Format('e_%d', [x])))).text:='0'; 产生报错 不知道什么原因呀 procedure Tfrm_cxcklx.sb_bcClick(Sender: TObject); var x,row,cul:Integer; begin for row:=0 to 25 do begin for cul:=0 to 7 do begin x:=8*row+(cul+1); if Assigned(FindComponent(Format('e_%d', [x]))) then TEdit(Assigned(FindComponent(Format('e_%d', [x])))).text:='0'; showmessage(TEdit(Assigned(FindComponent(Format('e_%d', [x])))).text); end; end; end;这是我程序代码
TEdit(Assigned(FindComponent(Format('e_%d', [x])))).text:='0';
产生报错 不知道什么原因呀
procedure Tfrm_cxcklx.sb_bcClick(Sender: TObject);
var x,row,cul:Integer;
begin
for row:=0 to 25 do
begin
for cul:=0 to 7 do
begin
x:=8*row+(cul+1);
if Assigned(FindComponent(Format('e_%d', [x]))) then
TEdit(Assigned(FindComponent(Format('e_%d', [x])))).text:='0';
showmessage(TEdit(Assigned(FindComponent(Format('e_%d', [x])))).text);
end;
end;
end;这是我程序代码