-1

I am a basic Excel user. I do a monthly rota which has the staff name in one cell and in the following cell it has the hours worked.

Is there a simple way to write an formula so that Excel takes any data from an adjacent cell with a name in and totals it up?

For example:

A1 - Mark   B1 - 5
A2 - Jane   B2 - 8
C1 - Mark   C1 - 5
D1 - Jane   D2 - 8

This continues with many more names throughout the month. Currently I am starting a cell with a staff name in and the in the adjacent cell doing =SUM() and then clicking each cell they work with a plus sign between.

e.g., A35 - Mark B35 - =SUM(b1+c1)

After my last response to another question, I am thinking there must be an easier way as this is very time-consuming and also prone to error.

2
  • Your cell layout doesn't make sense — you have two cells labeled C1; you have names in A1, A2, C1, and D1; and you have numbers in B1, B2, C1, and D2.  Please edit the question and fix that. Sep 14, 2015 at 0:00
  • Look at the SUMIF formula.
    – wbeard52
    Sep 14, 2015 at 0:40

1 Answer 1

0

Your question is pretty unclear to me, but I think you're looking to calculate sums of hours for names on a list. In that case, you can use sumif

Say your names are in column A and the hours are in column B - here's your total for "Mark"

=SUMIF(A1:A10,"Mark",B1:B10)

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .