SPREAD SHEET FORMULA

  • Thread starter Thread starter AINS
  • Start date Start date
A

AINS

I HAVE A SPREAD SHEET THAT I CANNT SORT WITHOUT MESSING UP THE FORMULAS THE
LAY OUT IS AT FOLLOWS

A B C
D
STATE ODOMETER START ODOMETER STOP MILES
PA
OH
NJ
CT
NH


I NEED A FORMULA TO ADD EACH STATES MILES AND OF COURSE THEY ARE NOT IN
ORDER, I NEED MY FORMULA TO RECOGNIZE THE STATE AND ONLY ADD THOSE MILES
TOGETHER??? HELP
 
If you understand your question correctly, this formula should give you the
totals you want...

=SUMPRODUCT((A2:A1000="NJ")*D2:D1000)

Just change the "NJ" to the state you want and change the range to cover the
maximum number of rows you think you will need (make sure the A range and
the D range are the same size).
 
Have a look in the help index for SUMIF. And, please quit SHOUTING. (typing
in all caps is considered to be RUDE)
 
Back
Top