Originariamente inviato da juricol
codice:
...
  rs.CursorLocation = adUseClient
  qstr = "select rascl2 from OTLQRY2_CGSTQ00 where rascl2='" & rec(2) & "'"
        rs.Open qstr, CurrentProject.Connection, adOpenKeyset, adLockOptimistic
          While Not rs.EOF
            rs(0) = rec(3) 'ragsoc
            rs.Update '<-- va in errore qui
            rs.MoveNext
          Wend
...
Ciao, fai così:

codice:
qstr = "UPDATE OTLQRY2_CGSTQ00 SET nomeCampoZero='" & rec(3) & "' WHERE rascl2='" & rec(2) & "';"

CurrentProject.Connection.Execute(qstr)