ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Worksheet Functions (https://www.excelbanter.com/excel-worksheet-functions/)
-   -   Worksheet Reference (https://www.excelbanter.com/excel-worksheet-functions/97229-worksheet-reference.html)

Lynn

Worksheet Reference
 
I would like the sheet name referenced in a formula to be relative to the
value in another cell. Examples:

If the value in cell A1 is 1 then my formula should be ='1'!B3

If the value in cell A1 is 2 then my formula should be ='2'!B3

Can this be done without programming? If so, how?

davesexcel

Worksheet Reference
 

=IF(Sheet3!A1=1,Sheet1!A1,IF(Sheet3!A1,Sheet2!A1," "))


--
davesexcel


------------------------------------------------------------------------
davesexcel's Profile: http://www.excelforum.com/member.php...o&userid=31708
View this thread: http://www.excelforum.com/showthread...hreadid=557672


Max

Worksheet Reference
 
Probably INDIRECT ..
Try in say, B1: =INDIRECT("'"&A1&"'!B3")
where A1 houses the sheetname
--
Max
Singapore
http://savefile.com/projects/236895
xdemechanik
---
"Lynn" wrote:
I would like the sheet name referenced in a formula to be relative to the
value in another cell. Examples:

If the value in cell A1 is 1 then my formula should be ='1'!B3

If the value in cell A1 is 2 then my formula should be ='2'!B3

Can this be done without programming? If so, how?


Lynn

Worksheet Reference
 
Thanks Max - this is perfect!

"Max" wrote:

Probably INDIRECT ..
Try in say, B1: =INDIRECT("'"&A1&"'!B3")
where A1 houses the sheetname
--
Max
Singapore
http://savefile.com/projects/236895
xdemechanik
---
"Lynn" wrote:
I would like the sheet name referenced in a formula to be relative to the
value in another cell. Examples:

If the value in cell A1 is 1 then my formula should be ='1'!B3

If the value in cell A1 is 2 then my formula should be ='2'!B3

Can this be done without programming? If so, how?


Max

Worksheet Reference
 
You're welcome, Lynn
Thanks for the feedback ..
--
Max
Singapore
http://savefile.com/projects/236895
xdemechanik
---
"Lynn" wrote:
Thanks Max - this is perfect!




All times are GMT +1. The time now is 07:52 AM.

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