I am using the new dynamic array functions introduced in Excel in 2018 (e.g. SEQUENCE, UNIQUE etc. functions).
I have a list of cell references that are generated dynamically and would like to apply the INDIRECT function to these list items. A simplified example:
cell A1: =SEQUENCE(5)
(results in rows column A values 1,2,3,4,5 as expected)
cell B1: ="A"&A1#
(results in rows column B values A1, A2, A3, A4, A5 as expected)
cell C1: =INDIRECT(B1#)
this should give me rows in column C values 1,2,3,4,5, but in fact gives me #VALUE ,#VALUE ,#VALUE ,#VALUE ,#VALUE
So the formula properly recognizes the number of rows of the original dynamic array, but for some reason does not dereference the cells properly. The strings seem to be of the proper format - a simple string function such as LEN also works: setting C1 to =LEN(B1#)
results in 5 rows of the value 2.
The syntax per se seems to be OK.. for the special case of =SEQUENCE(1)
in cell A1 everything works as intended. I tried the R1C1 reference format also, same result
EDIT
Overall I am trying to achieve the following
- import a list form a non-Excel data source - list is not a dynamic array, it's just a TSV import. I don't know beforehand how many items are in this list, and it can vary a lot
- do several different calculations on values of this list.
- so far my approach was to use the
COUNT
function to determine the number of items in the imported list, and then use that to create the second list usingSEQUENCE
andINDEX
to retrieve values. - the problem arises for some calculations where the data contains references to other rows so I have to use indirect addressing to get at that data