2

I would like to use the ARRAYFORMULA combined with two cells as range. For example:

Cell A1 value: A3
Cell A2 value: B7

Resulting formula: ARRAYFORMULA(A3:B7)

Is it possible? How can I do?

2

It's possible with

=arrayformula(indirect(A1 & ":" & A2))

Indeed, the string concatenation A1 & ":" & A2 produces the string "A3:B7", and indirect picks up the corresponding range.

Actually, =indirect(A1 & ":" & A2) is already enough to return an array of values, but arrayformula may be needed if you are going to do some computation with those values.


If the addresses in A1 and A2 refer to another sheet, only the first of them should have the sheet name: i.e., put Sheet2!A3 in A1 and simply B7 in A2. This is because stating sheet name twice is redundant, and indirect won't like that.

  • Thanks for the answer. It works with data in the same sheet, but what about using data in another sheet (in the same spreadsheet). For example, data and the cells with the ranges in sheet1 and using the arrayformula in sheet2. I tried it but it returns nothing. Something like =arrayformula(indirect(sheet1!A3 & ":" & sheet1!B7)) – Rods Dec 29 '17 at 12:32
  • @Rods Follow-up questions should be posted as new questions. – Rubén Dec 29 '17 at 15:51
  • @Rods It works, see my edit – user135384 Dec 29 '17 at 16:38

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.