3
votes

In Google Sheets, I have a cell named Income whose value is referencing a cell in another sheet named 7.17. I'm currently hard coding the reference. So, the value of Income is ='7.17'!B38, where B38 is the cell that contains the value of Income located in the sheet named 7.17.

I want to pass in a dynamic date reference instead. So, I can use =month(today()) in one cell to extract the current month, which returns an integer value, like 7 for July. I then want to use this as the reference value. In other words, instead of using ='7.17'!B38, I want to use something like =month(today()).17!B38.

=month(today()) can be in one cell, say A1, and its value (like 7) can be in a different cell, say A2. Then, I would do something like =A2.17!B38

How could I do this?

1

1 Answers

6
votes

You're looking for the INDIRECT function. Your 1st example could be expressed in this case as

=indirect(month(today()) & ".17!B38")