Create reference (tab name) based on cell values to create the link

hro5e

Board Regular
Joined
Jan 13, 2012
Messages
60
Hi,

I'm having real trouble in searching for the answer to my problems, perhaps I am not wording it correctly.

I have 2 tabs:

Sheet1
Sheet2

If I want the value in cell A2 from Sheet2 to be in cell A2 in Sheet1, the formula would simply be:

='Sheet2'!A2

Now I want to create a formula that pieces together the formula above based on the text in another cell.

So, I would want to recreate ='Sheet2'!A2 but I want the name 'Sheet2' to be taken from cell A1. So the idiots formula (in my head) would be:

='A1&"!"'&A2

Which would be the same as ='Sheet2!A2, which will get the data from A2 in Sheet 2.

The idea behind this, is that I need to extract data from certain tabs (sheets) but only based on the value of the data in A1 in Sheet 1.

So if the value in A1 in Sheet1 was:

SOO-1

the formula ='A1&"!"'&A2 would create the outcome ='SOO-1'!A2

Which ultimately searches and extracts the data in cell A2 from the sheet tab called SOO-1

I hope this makes sense.
 

Excel Facts

Formula for Yesterday
Name Manager, New Name. Yesterday =TODAY()-1. OK. Then, use =YESTERDAY in any cell. Tomorrow could be =TODAY()+1.
How about
Excel Formula:
=indirect("'"&A1&"'!A2")
 
Upvote 0
Solution
Hi, thanks for the swift reply,


I get this error message:ErrorFunction INDIRECT parameter 1 value is ''S001'!A2'. It is not a valid cell/range reference.
 
Upvote 0
Glad to help & thanks for the feedback.
 
Upvote 0

Forum statistics

Threads
1,224,813
Messages
6,181,117
Members
453,021
Latest member
Justyna P

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