Board index » delphi » Using ADO In MIdas program, I can not change a field's value

Using ADO In MIdas program, I can not change a field's value

HI,
   Using ADO in my midas program(MY database is msaccess97),I found that I
couldn't change a field's value.the following is my client code(I USE DELPHI
5)
 ...
 clientdataset2.edit;
 clientdataset2.fieldbyname('username').asstring:='def'; // original value
is 'abc'
 clientdataset2.applyupdates(0);
...

but I FOUND after this, the value of field 'username' is 'abc' but not
'def',why?

another question, I found use LOCATE property couldn't find the desired
record,why?

 

Re:Using ADO In MIdas program, I can not change a field's value


Quote
>but I FOUND after this, the value of field 'username' is 'abc' but not
>'def',why?

you need

ClientDataset2.post;
 clientdataset2.applyupdates(0);

--
Brian Bushay (TeamB)
Bbus...@NMPLS.com

Other Threads