google-sheets - how can I write a formula that uses a cell's contents when building a range reference to the name of another sheet? - TagMerge
2how can I write a formula that uses a cell's contents when building a range reference to the name of another sheet?how can I write a formula that uses a cell's contents when building a range reference to the name of another sheet?

how can I write a formula that uses a cell's contents when building a range reference to the name of another sheet?

Asked 1 years ago
1
2 answers

Try to remove the "'"& before D4 and the ' after the Overall.

Your formula should look like this:

=IFERROR(HLOOKUP($A$2,INDIRECT(F4 &" Overall!$A$5:$X$150", Utility!$A10, FALSE)))

Source: link

0

With Nikko's nudges in the right direction, I eventually figured out the right format. This allows the formula to work in multiple sheets and to be filled right (for more years) and down (for more classes).

=IFERROR(HLOOKUP($A$2,INDIRECT("'"D$4&" Overall'!$A$5:$X$150"), Utility!$A3, FALSE))

Note that if you try to replicate this, you may need to type the formula out from scratch—I had a problem where pasting it in didn't work. Once I'd retyped it and Google Sheets acknowledged it, it worked from then on in the spreadsheet, even when pasted from sheet to sheet.

Source: link

Recent Questions on google-sheets

    Programming Languages