简体   繁体   中英

Formula to Reference another Cell's Formula in Excel

I was teaching Vlookup to a coworker. We were trying to copy last month's spreadsheet, rename it to include the date, then reference another spreadsheet that is also renamed to include the current date.

Lets call the first spreadsheet Investor Statements and the second spreadsheet Value Per Investor. I copy Q3 2019 Investor Statements into a new folder and rename is Q4 2019 Investor Statements. Each quarter must be saved for auditing purposes. Then I copy the Q3 Value Per Investor into Q4 Value Per Invester. They are also saved into the Folder Q4 so that the file location is new.

The Investor Statements spreadsheet uses VLOOKUP to pull several values from the Value Per Investor spreadsheet. The problem is that since there is a new file location and a new file name, the VLOOKUP formula's range must be updated. There are roughly 50 investors so it is a pain to do copy and paste onto each page.
My first thought was to create a master Investor Statement spreadsheet and a master Value Per Investor spreadsheet. Then I could update the info in the Value Per Investor spreadsheet and have it update the VLOOKUP in the Investor Statements. This did not work because the file location for the VLOOKUP in the Investor Statement will remain the same and still reference the Master Value Per Investor sheet.

I need a way to update the VLOOKUP in Investor Statement without updating all 50 tabs. So my co-worker asked me why can't I just updated the first tab and have the other tabs reference that formula in that cell. This is similar to how we update the date. We put the date on the first tab and then on the second tab it is a link to that cell. This only works with VALUES however and not with FORMULAS.

I have been thinking about this problem since yesterday and I am hoping someone has an ingenious way around copying and pasting 50 times.

Thanks, Matt

I am going to presume you don't want to go down a VBA route, and I am sure someone will maybe have a better answer but have you not thought about a simple Find and Replace (CTRL+F)?

Just replace the current file location with the new location, Find and Replace All. It works within formulas.

在此处输入图片说明

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM