Dynamic Sheet using Drop Down List & INDIRECT using External File

sea_captain

New Member
Joined
Jan 10, 2017
Messages
11
Goal: Use a Drop Down list to Change Data that is linked to another file.

I have 2 files (file 1: 'SOURCE', and file 2: "OUTPUT") - the "Source" file feeds/links to the "Output" file (linking). The Output file is an Income Statement.
I want to use a drop down list to change the data in the income statement by Region/Service Line.
For example, i have tabs in the "Source" file named "US", "East", "Central" and "West". My dropdown list is US, East, Central and West (this is an example, i have a lot more 'tabs'). I want to use the dropdown to change the data from US to any other option in the list.

If everything was in the same file (source and output), i could easily do this using the INDIRECT function. FYI - All P&L's are UNIFORM - meaning Revenue is in the same Cell for each tab etc.

If dropdown list is in cell C5 and Revenue data is in Cell BL5 (in all tabs), i could use INDIRECT($C$5&"!BL5") to change the data.
The problem i'm having is the data is in another file and i'm not sure how to write it, because changing the "external link" cell, gives an error (for obvious reasons)
1704836840341.png

Any ideas? OR any other ideas using a drop down to change the P&L data.
Thanks - SC
 

Excel Facts

Workdays for a market open Mon, Wed, Friday?
Yes! Use "0101011" for the weekend argument in NETWORKDAYS.INTL or WORKDAY.INTL. The 7 digits start on Monday. 1 means it is a weekend.
INDIRECT will not work for external sources. To fix the issue, you can recreate tables from other workbooks in your current workbook using links. Then use INDIRECT to reference those tables.

Am I reading this right? You want to change values in another workbook or in your current workbook?
 
Upvote 0
Solution
Assuming that you Source filename is Source.xlsx, and you have sheets Sheet1 and Sheet2 for example

Source.xlsx
A
1Data in Sheet1
Sheet1

Source.xlsx
A
1Data In sheet2
Sheet2


you could do this (dropdown in A1):

Output.xlsx
AB
1Sheet1Data in Sheet1
Sheet1
Cell Formulas
RangeFormula
B1B1=INDIRECT("'[Source.xlsx]"&A1&"'!$A$1")
Cells with Data Validation
CellAllowCriteria
A1ListSheet1, Sheet2


For this to work you will have to open the source file
 
Upvote 0
Let me rephrase my statement: INDIRECT won't work for external workbooks that are not open at the same time by you.
 
Upvote 0
Thanks. I added a bunch of hidden tabs withe the data needed. So the source data is now in the Output file. Not what I wanted , but I will give your suggestion a go. Thanks again. -sc
 
Upvote 0
Thanks. I added a bunch of hidden tabs withe the data needed. So the source data is now in the Output file. Not what I wanted , but I will give your suggestion a go. Thanks again. -sc
The marked solution has been changed accordingly. In your future questions, please mark the post as the solution that actually answered your question, instead of your feedback message as it will help future readers. No further action is required for this thread.
 
Upvote 0

Forum statistics

Threads
1,215,076
Messages
6,122,984
Members
449,092
Latest member
Mr Hughes

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