with Panel38 do
begin
for i:=0 to ControlCount-1 do
begin
if Controls[i].ControlStyle ='TEdit' then
TEdit(Controls[i]).ReadOnly := true;
end;
end;
程序运行无报错,无反应。
是哪儿错了,请大家指教指教。谢谢!
begin
for i:=0 to ControlCount-1 do
begin
if Controls[i].ControlStyle ='TEdit' then
TEdit(Controls[i]).ReadOnly := true;
end;
end;
程序运行无报错,无反应。
是哪儿错了,请大家指教指教。谢谢!
for I := ControlCount - 1 to 0 do
begin
..........
end;
同时建议用Controls[i] is TEdit来判断
begin
for i:=0 to ControlCount-1 do
begin
if Controls[i] is TEdit then //用is来判断类型
TEdit(Controls[i]).ReadOnly := true;
end;
end;