# ARRAYTOTEXT

## Content

The ARRAYTOTEXT function returns an array of text values from any specified range. It passes text values unchanged, and converts non-text values to text.

## Syntax

`ARRAYTOTEXT(array, [format])`

## Arguments

This function has these arguments:

| @cols=1:**Argument** | @cols=1:**Description** |
| -------- | ----------- |
| @cols=1:@rows=1:*array* | @cols=1:@rows=1:[Required] The range or array to return as text. |
| @cols=1:@rows=1:*format* | @cols=1:@rows=1:[Optional] The format of the returned data. It can be one of two values:<ul><li>**0**    Default. Concise format that is easy to read. The text returned will be the same as the text rendered in a cell that has general formatting applied.</li><li>**1**    Strict format that includes escape characters and row delimiters. Generates a string that can be parsed when entered into the formula bar. Encapsulates returned strings in quotes except for Booleans, Numbers and Errors.</li></ul> |

## Remarks

* The ARRAYTOTEXT function does not support 3D references such as `=Sheet2:Sheet3!A1:C3`; otherwise, it will return a `#VALUE!` error.
* If the *format* argument is a number or string greater than or equal to 0 and less than 1, it is treated as 0; if it is greater than or equal to 1 and less than 2, it is treated as 1.
* If the *format* argument is TRUE, it is treated as 1; if FALSE, it is treated as 0.
* If the *format* argument is a string type, unless its value is greater than or equal to 0 and less than 2, the formula will return a `#VALUE!` error.
* If the *format* argument itself is of an error type (for example, `=ARRAYTOTEXT("aaa", #DIV/0!)`), or if the argument causes an error during calculation (for example, `=ARRAYTOTEXT("aaa", 10/0)` ), the final result will display as an error type and will not be converted to text.

## Example

![image](https://cdn.mescius.io/document-site-files/images/ae7843c3-c78e-4c99-ad9b-232e3606de10/image.737d14.png?width=750)