Using ADDRESS in INDIRECT

Kiriko

New Member
Joined
May 15, 2018
Messages
16
Hi


I need to extract the totals of separate sheets to a summary sheet in one workbook. The total row is not always on the same row in every sheet although the set-up is basically the same.
I have tried to use a combination of INDIRECT & ADDRESS but the required information needs to be referenced both by row and column so I nested MATCH into the ADDRESS formula
The ADDRESS formula works but I can't get INDIRECT to read it as a cell ref, see below details:
FXWritten OutWith Cell referencesReturnsPurpose
INDIRECTINDIRECT(Sheet name & "! Total Cell Ref ")INDIRECT(A1&"!B6")79Returns the amount in the total row which is located in cell B6 in sheet 1
ADDRESSADDRESS(Row number, Column number)ADDRESS(6,2)B6Returns in text value the cell address or reference to the cell containing the total for sheet 1 data
MATCHMATCH(Lookup value,lookup array,0)MATCH("Total",INDIRECT(Sheet 1&"!A:A"),0)6Returns the row number to be used in Address fx
MATCHMATCH(Lookup value,lookup array,0)MATCH("2018",INDIRECT(Sheet 1&"!3:3"),0)2Returns the column number to be used in Address fx
So I want to do something like:
INDIRECT(A1&"!ADDRESS(MATCH("Total",INDIRECT(Sheet 1&"!A:A"),0),MATCH("2018",INDIRECT(Sheet 1&"!3:3"),0))")
Where my end result should be 79 which is located in Sheet 1 Cell B6
BUT:
Excel will only accept
INDIRECT(A1&ADDRESS(MATCH("Total",INDIRECT(Sheet 1&"!A:A"),0),MATCH("2018",INDIRECT(Sheet 1&"!3:3"),0)))
And it gives me a #REF error
Any ideas would be appreciated
<colgroup><col width="99" style="width: 74pt; mso-width-source: userset; mso-width-alt: 3620;"> <col width="279" style="width: 209pt; mso-width-source: userset; mso-width-alt: 10203;"> <col width="289" style="width: 217pt; mso-width-source: userset; mso-width-alt: 10569;"> <col width="151" style="width: 113pt; mso-width-source: userset; mso-width-alt: 5522;"> <col width="402" style="width: 302pt; mso-width-source: userset; mso-width-alt: 14701;"> <tbody> </tbody>
 

Excel Facts

How to fill five years of quarters?
Type 1Q-2023 in a cell. Grab the fill handle and drag down or right. After 4Q-2023, Excel will jump to 1Q-2024. Dash can be any character.
See if this works
Assumes the sheet name in A1 doesn't contain spaces (like Sheet1 for example). Otherwise you should use single quotes around A1.

=INDEX(INDIRECT(A1&"!A:Z"),MATCH("Total",INDIRECT(A1&"!A:A"),0),MATCH("2018",INDIRECT(A1&"!3:3"),0))

M.
 
Upvote 0

Forum statistics

Threads
1,215,094
Messages
6,123,069
Members
449,092
Latest member
ipruravindra

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