还哥们我们有同样的经历虽然我没明白为什么但是我换钟方法让过去了
var LogionObj2:Imts_data;
OwnerData
leVariant;
Irecout:integer;
Params
leVariant;
Options:TgetrecordOptions;
Str:string;
i,a
word;
begin
if Mts_data2.Text='' then
begin
Showmessage('Input');
exit;
end;
button21.Enabled:=false;
i:=gettickcount();
Options :=[grmetadata,grreset];
STr:='select * from T_Mts Where id='+Trim(Mts_data2.Text);
LogionObj2:=CoMts_data.Createremote(Trim(Mts_edit1.text));
ClientDataset3.Data:=LogionObj2.AS_getRecords('DataSetProvider2',-1,Irecout,Byte(options),Str,Params,OwnerData);
A:=Gettickcount();
Mts_timer4.Text:=inttostr(A-i);
Showmessage('ok');
BUtton21.Enabled:=true;
这是出问题的代码;
var LogionObj2:Imts_data;
a,i
word;
begin
if Mts_data2.Text='' then
begin
Showmessage('Input');
exit;
end;
button20.Enabled:=false;
a:= gettickcount();
LogionObj2:=CoMts_data.Createremote(Trim(Mts_edit1.text));
ClientDataset3.data:= LogionObj2.GetOneRecord(STrtoint(Mts_data2.Text));
I:=gettickcount();
Mts_timer3.Text:=inttostr(i-a);
Showmessage('ok');
button20.Enabled:=true;
这是不出问题的代码,
哥们试试看有问题咱们网上了,我得qq:76549704