ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Discussion (Misc queries) (https://www.excelbanter.com/excel-discussion-misc-queries/)
-   -   Pulling info from multiple worksheet tabs? (https://www.excelbanter.com/excel-discussion-misc-queries/115360-pulling-info-multiple-worksheet-tabs.html)

Paul

Pulling info from multiple worksheet tabs?
 
I have a summary page that pulls from multiple worksheet tabs, call them 1, 2
and 3. On the summary page I want to sum specific cells on a tab, say cell
a1,a2,a3. Can I on the summary sheet make a formula that will sum those
cells, but be flexible enough to recognize what tab I want summed by
referencing another cell on the summary page? In other words if I put 1 in
cell a1 on the summary sheet it will know to go to worksheet 1 and sum the
right cells, and if I put 2 in A1 it will know to sum those cells on
worksheet 2?

Pete_UK

Pulling info from multiple worksheet tabs?
 
Try this in your summary sheet:

=IF(OR(A1<1,A13),"",SUM(INDIRECT("Sheet"&INT(A1)& "!A1:A3")))

where A1 on the summary sheet is used to hold 1, 2 or 3, and depending
on this value the sum will be returned from cells on Sheet1, Sheet2 or
Sheet3. If A1 is out of range then you will have a blank result.

Hope this helps.

Pete

Paul wrote:
I have a summary page that pulls from multiple worksheet tabs, call them 1, 2
and 3. On the summary page I want to sum specific cells on a tab, say cell
a1,a2,a3. Can I on the summary sheet make a formula that will sum those
cells, but be flexible enough to recognize what tab I want summed by
referencing another cell on the summary page? In other words if I put 1 in
cell a1 on the summary sheet it will know to go to worksheet 1 and sum the
right cells, and if I put 2 in A1 it will know to sum those cells on
worksheet 2?




All times are GMT +1. The time now is 02:41 AM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com