GingerStepChild
New Member
- Joined
- Oct 27, 2016
- Messages
- 28
Hi,
In a cell G19 I have the following to get the sheetname:
=MID(CELL("filename",A1),FIND("]",CELL("filename",A1))+1,20)
The format type is General but all the sheetnames will be numbers.
This sheetname value is manually entered into column A of a table on another sheet called 'Summary'. Type is also "General'
There are 4 columns in the table and I require data from 2 other columns which I get from using an Index/Match
=INDEX(Summary!$B$6:$B$24,MATCH($G$19,Summary!A6:A24,0))
=INDEX(Summary!$C$6:$C$24,MATCH($G$19,Summary!A6:A24,0))
So far so good.
My problem is when I reference the cells that has the sheetname formula, G19 it returns #N/A, which makes me sad.
When I change my reference cell to G18 it returns the values I need.
I do note that when I am checking the formula the G19 value is "2017010" (with quotes) while G18 is 2017010 without quotes.
So, what do I need to do to the sheetname formula cell G19 so my index match works correctly. I have been sniffing about INDIRECT but am not sure I understand it correctly.
Thanks in advance for your help.
In a cell G19 I have the following to get the sheetname:
=MID(CELL("filename",A1),FIND("]",CELL("filename",A1))+1,20)
The format type is General but all the sheetnames will be numbers.
This sheetname value is manually entered into column A of a table on another sheet called 'Summary'. Type is also "General'
There are 4 columns in the table and I require data from 2 other columns which I get from using an Index/Match
=INDEX(Summary!$B$6:$B$24,MATCH($G$19,Summary!A6:A24,0))
=INDEX(Summary!$C$6:$C$24,MATCH($G$19,Summary!A6:A24,0))
So far so good.
My problem is when I reference the cells that has the sheetname formula, G19 it returns #N/A, which makes me sad.
When I change my reference cell to G18 it returns the values I need.
I do note that when I am checking the formula the G19 value is "2017010" (with quotes) while G18 is 2017010 without quotes.
So, what do I need to do to the sheetname formula cell G19 so my index match works correctly. I have been sniffing about INDIRECT but am not sure I understand it correctly.
Thanks in advance for your help.