MrExcel Publishing
Your One Stop for Excel Tips & Solutions

running totals


Posted by Suzanne on October 27, 2000 12:24 PM

I have a spreadsheet which I use to order materials from a contract. I have columns for Material description, Quantity Ordered, Price, & Extended Price. And off the right or even on another sheet of the worksheet, I would like a column to keep a running total of the Quantity of each item purchased off this Contract for tracking purposes.

I can't seem to figure out how to do this, can you help me?


Posted by Ben O. on October 27, 2000 1:03 PM

{=SUM(IF(Description="A",Quantity,0))}

Name the column with the materials descriptions, "Description" and the column with the quantities, "Quantity." You could also replace the word "Description" with a range, such as A2:A200.

This formula will sum the quantities for all items named, "A". Change "A" in the formula to the description of whatever item you want to count. You can also change it to a cell reference.

Note that it an array formular, so press Crtl+Shift+Enter when entering it.

Hope you get it to work,

-Ben


{=SUM(IF(Description="A",Quantity,0))}