I sum the result of [credit]-[debit], so yes the same fields
No, the queries always have the same sort order which is a date field. I will try your solution tomorrow and come back, thanks once more.
What I actually want to do, is have a running sum query, as recordset in a form - I did that.
But when I change the recordsource of the form from a list box, the query uses the table(logically) for the domain of the DSum function.
That is why I asked of the domain of the DSum function can be...
The syntax is: DSum(expr, domain, [criteria])
I want to use the dSum function, and I want to use my forms recordset the domain to be inserted in the query, is this possible? and how?
No, you got me wrong. What worked is the way to paste the code correctly in this forum.
The form still produces the #error as per my first post in this thread [sadeyes]
Test to see if it works..
Private Function SubSum()
'*************************************************************
'* pkName - Existing unique fieldname (usually primarykey) *
'* sumName - Name of the field to runsum *...
Sorry theAceman1 but the code was copied from your own code in the previous post, and I manually changed the names of the fields and inserted the "[c0de][/code] afterwards. This forum does not offer editing of your own posts (unless I can't see an edit button), so I could not make it to look...
Private Function SubSum()'*************************************************************'* pkName - Existing unique fieldname (usually primarykey) *'* sumName - Name of the field to runsum *'************************************************************* If Trim(Me!AA &...
Hello,
I have copied and adjusted the code from the FAQ: http://www.tek-tips.com/faqs.cfm?fid=5248 by TheAceMan1, but I seem to always get error in the control in Question.
My knowledge in VBA is not very good, so help would be deeply appreciated.
Forms name = Data (continuous forms)...
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.