Subtracing from Previous Line in Report to make running total (1 Viewer)

jordankoal

Registered User.
Local time
Yesterday, 23:43
Joined
Sep 5, 2013
Messages
29
I can't seem to find the answer to this. I saw a thread on here but it lead to a dead end. What I am trying to accomplish is the following:

I have a database and one of the functions is to track the purchase of fuel. Part of purchasing fuel is registering what the current odometer reads. My query gets the Vehicle ID, Date of Transaction and Odometer reading. I want to show a report that shows how many miles the vehicle is has traveled for a certain amount of time. If it's for 2013 then I'll put the criteria for 2014 in the date. This will give me a list of all vehicles and their odometer readings. I then sort the date by ascending.

In the report I group on vehicle ID and then I want to show all their transactions and add up how many miles were driven.

Vehicle 1

1/2/201
1/5/2013
1/15/2013
ETC...
Total Miles Driven in 2014: XXXXXX

Any suggestions?
 

GohDiamond

"Access- Imagineer that!"
Local time
Today, 00:43
Joined
Nov 1, 2006
Messages
550
If you are using a real REPORT object (not calling some other object your "report", like a recordset produced by a query) in MS access you can easily do this with the Report Wizard. Just tell it which field you want your total on. Once you have the actual REPORT then look at it on design view to see how it was accomplished.

Look here for more information on how to build a Summary Report with supporting details: http://office.microsoft.com/en-us/access-help/summing-in-reports-HA001122444.aspx

Cheers!
Goh
 

Users who are viewing this thread

Top Bottom