for i:=0 to form1.ControlCount do
begin
if form1.Controls[0] is Tedit then
???????//这句该怎么写??
end;
我的EDIT非常多,不能一个一个写代码
begin
if form1.Controls[0] is Tedit then
???????//这句该怎么写??
end;
我的EDIT非常多,不能一个一个写代码
解决方案 »
- 用D新做了一个友情链接检测工具!
- 好多的问题,无法理清了,请来帮帮,拉我一把
- 怎么在退出程序时出现提示框?
- 请问怎样遍历所有的菜单项啊?
- 2天内揭帖,在线等待,dbgrid问题,高手请进!
- 看完代码后请帮助我
- 如何把在image控件上绘制的图象保存成网页?
- 请yczyk有鬼进来接分!感谢你的帮忙!
- 各位:你们好!我想做一个类似word中的公式编辑器,选择某个公式,输入相关数据后生成图片!将它做成插件的形式,能给点思路吗?
- 难!如何给OnGetText事件动态赋值?事件的执行过程写在另一个Delphi的DLL中,有请大虾
- 请问如何将鼠标所在屏幕坐标位置换算成鼠标所在控件的位置?
- 问一个SQL语句,如何查询TableA中的一个字段在TableB中的一个字段没有的纪录
if Components[I].ClassType = TEDIT then
with Components[i] as TEDIT do
begin
Text:='';
end
i:integer;
begin
for i:=0 to ControlCount-1 do
if (Controls[i] is TEdit) then
TEdit(Controls[i]).Clear;
end;
begin
if Controls[i] is TEdit then
TEdit(Controls[i]).Text := '';
end;搞定!
if (components[i] is Tedit)then
(components[i] as TEdit).Text:='';
for i:=0 to form1.componentcount-1 do
if (form1.components[i] is Tedit)then
(form1.components[i] as TEdit).Text:='';
if (components[i] is Tedit)then
(components[i] as TEdit).Text:='';
var i:integer;
begin
for i:=0 to self.ComponentCount-1 do
begin
if (self.Components[i] is Tedit) then
begin
Tedit(Components[i]).Clear;;
end;
end;
end;