Using Memo field
Posted on 2003-03-05
I am making a program that updates a memo field using an adodb recordset. I need to update the field by adding text to the end. But when I open the recordset for some reason it overwrites the existing text. I beleive it has to do with the lockcode. when I do not set a lockcode I am able to view the memo in a textfield, but I am not able to update the field. When I set it to any other lockcode I cannot view it, but I can update it but it overwrites the current text. Here is my code...
'Open Comments Recordset
sqlMemo = "SELECT MemoField FROM Comments"
Set rsMemo = New ADODB.Recordset
rsMemo.LockType = adLockOptimistic
Call rsMemo.Open(sqlMemo, connAccounts)
rsMemo.Fields("MemoField").Value = rsMemo.Fields("MemoFeild").Value & "Updated Text"
This let's me update but overwrites existing data. HELP!