Again: How to copy a memo



Hi,
yesterday, I got some tipps, how to copy a memo (ADO,D7)
I tried a lot now, but it still don't work.
When I post, then I get a exception. (when I don't post, then the value is
not saved)
Question: with which AdoComponent can I change a field with assign ?
TADOQuery or TADODataset ?

Thanks
Willi



dsShop := tAdoDataSet.create(Application);
dsShop.Connection := pShopADOConn;
dsShop.CommandText := 'Select Mess from MessO where Nummer=' +
inttostr(NummerArr[ii]) ;
dsShop.Open;
//
dsZent := tAdoDataset.create(Application);
dsZent.Connection := pConnZentRW;
dsZent.CommandText := 'Select Mess from MessZwisch where
Nummer=' + inttostr(NewNum) ;
dsZent.Open;
//
dsZent.Edit;
dsZent.FieldByName('Mess').assign(dsShop.FieldByName('Mess'));
if dsZent.State in [dsEdit] then begin
dsZent.Post;
end;
//
dsShop.close;
dsShop.free;
dsZent.close;
dsZent.free;


.



Relevant Pages