2,497
社区成员
发帖
与我相关
我的任务
分享
if Frm.Components[i] is tadoquery then
begin
if (Frm.Components[I] as tadoquery).State <> dsInactive then
begin
(Frm.Components[I] as tadoquery).Connection:=nil;
data1.adoConnection1.Close;
data1.adoConnection1.Open;
(Frm.Components[I] as tadoquery).Connection:=data1.adoConnection1;
end;
end;