Here is one that works

M

Mark A. Sam

I was checking over my code and discovered this this procedure for
renumbering line items works fine in adding records to the recordsetclone:

Private Sub Form_AfterUpdate()

'Number lines - Store in [detItem]
Dim rs As Recordset
Dim I As Integer
Set rs = Me.RecordsetClone

rs.MoveFirst

Do Until rs.EOF
I = I + 1
rs.Edit
rs![detItem] = I
rs.Update
rs.MoveNext
Loop

Set rs = Nothing

End Sub
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top