Syntax
=INDIRECT(ref_text, [a1])Arguments
| Argument | Required | Description |
|---|---|---|
ref_text | Required | The reference as text (A1 or R1C1 style, a name, or a sheet reference) |
a1 | Optional | TRUE (default) for A1 style text, FALSE for R1C1 style |
How to use INDIRECT
INDIRECT is volatile: it recalculates every time the workbook changes, so its result can differ each time.
INDIRECT takes 1 required argument and 1 optional argument. Type =INDIRECT( in a cell and SheetsBat shows the arguments as you go. Optional arguments are shown in square brackets; leave them out to use their default.
Examples
Each result below was calculated by the SheetsBat formula engine.
=INDIRECT("B2")Result Data in the sheet
| B | |
|---|---|
| 2 | 7 |
=INDIRECT("R2C2", FALSE)Result Data in the sheet
| B | |
|---|---|
| 2 | 7 |
=INDIRECT("not a ref")Result Related lookup and reference functions
- FORMULATEXTReturns the formula in a cell as text.
- GETPIVOTDATAReturns data from a pivot table. Refer to the pivot table cells directly instead.
- HLOOKUPLooks for a value in the first row of a table and returns the value in the same column from another row.
- INDEXReturns the value or reference at a given row and column of a range or array.
- LOOKUPFinds a value in a sorted row or column and returns the value at the same position in another row or column.
- MATCHReturns the position of a value in a row or column.
- OFFSETReturns a reference shifted a number of rows and columns from a starting reference, optionally with a new size.
- ROWReturns the row number of a reference, or of the cell with the formula when left out.
- ROWSReturns the number of rows in a range or array.