ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Worksheet Functions (https://www.excelbanter.com/excel-worksheet-functions/)
-   -   Formula to a sheet name that is text in another cell (https://www.excelbanter.com/excel-worksheet-functions/221670-formula-sheet-name-text-another-cell.html)

lauren_marie

Formula to a sheet name that is text in another cell
 
Is it possible to change the formula below so that the worksheet being
referenced is dependent on another cell?

=VLOOKUP($C$4,'Sheet 1'!$H$15:$M$75,2,FALSE)

So if I have
Sheet 1
Sheet 2
Sheet 3 etc in column A, can I reference the vlookup formula to pick up the
worksheet name from column A?


Pete_UK

Formula to a sheet name that is text in another cell
 
Yes, you would use INDIRECT to do that, like this:

=VLOOKUP($C$4,INDIRECT("'"&A1&"'!$H$15:$M$752"),2, FALSE)

assuming the first sheet name is in A1, and then copy this down as
required.

Hope this helps.

Pete

On Feb 20, 12:54*am, lauren_marie
wrote:
Is it possible to change the formula below so that the worksheet being
referenced is dependent on another cell?

=VLOOKUP($C$4,'Sheet 1'!$H$15:$M$75,2,FALSE)

So if I have
Sheet 1
Sheet 2
Sheet 3 etc in column A, can I reference the vlookup formula to pick up the
worksheet name from column A?




All times are GMT +1. The time now is 02:37 PM.

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