是否可用循环的方法设置多个组件的属性? 例如有 Label1 Label2 Label3......是否可用循环的方法设置各Label的Caption属性? 解决方案 » 免费领取超大流量手机卡,每月29元包185G流量+100分钟通话, 中国电信官方发货 虽然这个应用很方便,但是问的次数也太多了点procedure TForm1.Button1Click(Sender: TObject);var i: integer;begin for i:=1 to 4 do if FindComponent('Label'+IntToStr(i)) <> nil then TLabel(FindComponent('Label'+IntToStr(i))).Clear;end; 谢谢!谢谢!这个clear不行的吧,但已经明白了。 record 结构定义(简单问题) 100分,求40行JAVA代码翻译成DELPHI代码,会JAVA的DELPHI高手进!! 不使用数据源,直接将TStringList的数据显示到DBGrid中,怎么写呢?谢谢!! dxGrid字段动态设置 在厦门找个程序员工作怎么这么难? 改变工程属性为什么不能让程序自动增加版本号? 菜鸟的问题:listindex out of bounds(2)是什么意思?看看吧,谢谢! 如何自定义过程 這條信息是什麼意思.... 哪里有可打印的条形码控件下载?急 请教:如何ActiveX添加自定义事件? 请问如何解决TClientSocket的11001异常问题?
var
i: integer;
begin
for i:=1 to 4 do
if FindComponent('Label'+IntToStr(i)) <> nil then
TLabel(FindComponent('Label'+IntToStr(i))).Clear;
end;
这个clear不行的吧,但已经明白了。