For Mark A Sam? - slow textbox problem

L

Leslie Isaacs

Hello Mark

Many thanks for your response to my post made on 4 June, and apologies for
not getting back to you sooner - I've been away! I'm posting this as new
because I felt it was unlikely that you would check for responses on posts
over a week old.

I couldn't get your function (copied below) to work. I asume that I should
have pasted the code into a module and then set the conrol source of the
form's textbox to =RunningSum([balance]). When I do this I just get #name?
in each record's 'balance' field.

What have I done wrong.
Thanks again.
Les

The code:

Public Sub RunningSum()
On Error Resume Next

Dim cBal As Currency
With Me.RecordsetClone
.MoveFirst
Do Until .EOF
cBal = cBal + ([amount credit]-[amount])
![Balance] = cBal
.Update
.MoveNext
Loop
End With

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