边
边城过客
Unregistered / Unconfirmed
GUEST, unregistred user!
DELPHI+SQL2000+scktsrvr:<br> 在做客户端数据修改时,能修改本地的clientDataset1,但提交后不能修改服务器上的数据,源码如下:<br> with clientDataSet1 do //进行修改<br> begin<br> clientDataset1.Edit;<br> clientdataset1.fieldbyname('jgdm').asstring:=edit1.text;<br> clientdataset1.fieldbyname('jgjb').asstring:=ComboBox1.text;<br> clientdataset1.fieldbyname('xm').asstring:=edit2.text;<br> clientdataset1.fieldbyname('bm').asstring:=edit3.text;<br> clientDataSet1.ApplyUpdates(-1);<br> end;<br> end<br> else //新增处理<br> begin<br> with ClientDataSet1 do<br> begin<br> ClientDataset1.insert;<br> clientdataset1.fieldbyname('jgdm').asstring:=edit1.text;<br> clientdataset1.fieldbyname('jgjb').asstring:=ComboBox1.text;<br> clientdataset1.fieldbyname('xm').asstring:=edit2.text;<br> clientdataset1.fieldbyname('bm').asstring:=edit3.text;<br> ClientDataSet1.ApplyUpdates(-1);<br> end;<br> 以上代码能做服务器端的新增处理,但不能做服务器端的数据修改.麻烦高手们指点迷津.