Sum

mithani

Registered User.
Local time
Tomorrow, 06:01
Joined
May 11, 2007
Messages
291
Hi all,

I have one form with subform. Two tables are using Parent & child table. Subform is in tabular form. I have three fields, invoice #, date & amount in subform. I want to include one more field for sum. I don't know what you call this kind of sum:

invoice, date, amount, sum
1001, 12/02/05, 2400, 2400
1002, 13/02/05, 1000, 3400
1003, 14/02/05, 2000, 5400
1004, 16/02/05, 1000, 6400

thanks for your help

mithani
 
Hello mithani!

Look at "DemoRunningSumA2002.mdb" (attachment).
I think it is what you want.
Look at Tables, Query, Forms, (VBA), Module1.
Take care on "invoice" (first record), I purposely put
1007 before 1006.
 

Attachments

MStef, so kind of you
 
MStef,

My running sum is working great. How about if I want the running date and wants to calculate days? Bellow are two text boxes "Date" & "Day"

Date/Days
12/02/2007/ (first date should be date()-12/02/2007)
14/02/2007/2 days came(14/02/2007-12/02/2007)
18/02/2007/4 days came(18/02/2007-14/02/2007)
22/02/2007/6 days came(22/02/2007-18/02/2007)

Thanks man

mithani
 
Here it is, a new one.
I think it is what you need.
It is very important that the value in the field "INVOICE" flow consecutive.
There must not be 1001, 1005, 1002, and s.o.
You can add a code to check this, I have no time for this.
 

Attachments

Users who are viewing this thread

Back
Top Bottom