VLOOKUP across multiple sheets

Met Fan

Board Regular
Joined
Jul 1, 2004
Messages
185
I have a spreadsheet that records payroll. Within the file there are 52 worksheets (one per week for the entire year).

Every worksheet is formatted identically. I would like to add a 53rd tab that totals all of the entries in the weekly sheets. I want to use VLOOKUP because there is no guarantee that new employees will not be added or existing ones removed during the year.

Is there anyway to do a global VLOOKUP throughout the sheet or do I have to add a formula that adds each individually such as:
=VLOOKUP(B5,'01.06.09'!B3:K40,6,FALSE)+=VLOOKUP(B5,'01.13.09'!B3:K40,6,FALSE)+ ...

THANKS
 

Excel Facts

Did you know Excel offers Filter by Selection?
Add the AutoFilter icon to the Quick Access Toolbar. Select a cell containing Apple, click AutoFilter, and you will get all rows with Apple
Thank you for the input. I've entered the following formula:

=sumproduct(sumif(indirect("'"&SheetList&"'!B3:B29),B3,Indirect(""&SheetList&'''!G3:G29")))

I've created a list of the tab names and called the range SheetList.
B3:B29 contains the list of employee names
B3 contains the name of the employee I am adding the time up for.
G3:G29 contains the range withing the various weeks where the hours are to be added.

When I hit enter I am told my function contains too few arguments. When I hit OK the cursor goes to a point between the first and second Parenthese at the end of the formula.

Can you tell what I am doing incorrectly?
 
Upvote 0
Thank you for the input. I've entered the following formula:

=sumproduct(sumif(indirect("'"&SheetList&"'!B3:B29),B3,Indirect(""&SheetList&'''!G3:G29")))

I've created a list of the tab names and called the range SheetList.
B3:B29 contains the list of employee names
B3 contains the name of the employee I am adding the time up for.
G3:G29 contains the range withing the various weeks where the hours are to be added.

When I hit enter I am told my function contains too few arguments. When I hit OK the cursor goes to a point between the first and second Parenthese at the end of the formula.

Can you tell what I am doing incorrectly?

I think it's just missing some quotes...

=SUMPRODUCT(SUMIF(INDIRECT("'"&SheetList&"'!B3:B29"),B3,INDIRECT("'"&SheetList&'''!G3:G29")))
 
Upvote 0
=SUMPRODUCT(SUMIF(INDIRECT("'"&SheetList&"'!b3:b9"),B3,INDIRECT("'"&SheetList&"'!G3:G29")))

I tried the above formula and it returns #REF!
 
Upvote 0
I revised it to:
=SUMPRODUCT(SUMIF(INDIRECT("'"&SheetList&"'!b3:b9"),B3,INDIRECT("'"&SheetList&"'!G3:G29")))

and it returns #REF!
 
Upvote 0
I appreciate you assistance to date. I've changed to formula to:

=SUMPRODUCT(SUMIF(INDIRECT("'"&SheetList&"'!b3:b29"),B3,INDIRECT("'"&SheetList&"'!G3:G29")))

I still get #REF! When I enter the formula the range b3:b29 does not change to caps. Can this be where the problem lies?
 
Upvote 0

Forum statistics

Threads
1,214,591
Messages
6,120,426
Members
448,961
Latest member
nzskater

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top