VALUETOTEXT

VALUETOTEXT(value [,format])

Returns the value converted to text.

valueThe value to convert to text.
format(Optional) The format:
0 = easy to read format, concise (default)
1 = array format with curly brackets, strict.

REMARKS
* This function was added in Microsoft 365.
* Any text values are unchanged and any non-text values are converted to text.
* Numerical values are aligned on the right by default.
* Text values are aligned on the left by default.
* Boolean values (such as True and False) are aligned in the center by default.
* If "format" = 1, then escape characters and row delimiters may be included in the generated string. This string can be parsed when entered into the formula bar. This encapsulates returned strings in quotes except for Booleans, Numbers and Errors.
* If "format" is anything other than 0 or 1, then #VALUE! is returned.
* You can use Text to Columns to convert values to text.
* You can use the ARRAYTOTEXT function to return the contents of an array or cell range converted into text.
* You can use the CONCAT function to return a text string that is a concatenation of cell ranges and strings.
* You can use the ISTEXT function to return True or False depending if the value is text.
* You can use the TEXT function to return a number as a formatted text string.
* This function was released in July 2021.
* For the Microsoft documentation refer to support.microsoft.com

 AB
1=VALUETOTEXT(100,1) = 10010
2=VALUETOTEXT(-100,1) = -10020
3=VALUETOTEXT(TRUE) = -1Ge0eral
4=VALUETOTEXT(FALSE) = 0 
5=VALUETOTEXT("some text") = some text 
6=VALUETOTEXT("20 some text") = 20 some text 
7=SUM(B1:B2) = 30 
8=SUM(VALUETOTEXT(B1),20) = 30 
9=VALUETOTEXT({10,20,30},0) = {10,20,30} 
10=VALUETOTEXT({10,20,30},1) = {10,20,30} 

1 - What is the number 100 converted to text. It is 100 and is aligned on the left.
2 - What is the number -100 converted to text. It is -100 and is aligned on the left.
3 - What is the value TRUE converted to text. It is "TRUE" and is aligned on the left.
4 - What is the value False converted to text. It is "FALSE" and is aligned on the left.
5 - What is the value "some text" converted to text. No change.
6 - What is the value "20 some text" converted to text. No change.
7 - What is sum of the values in cell range "B1:B2".
8 - What is sum of 10 converted to text plus 20. The text "10" is automatically converted back to a number.
9 - What is the array of values {10,20,30} converted to text.
10 - What is the array of values {10,20,30} converted to text.

© 2022 Better Solutions Limited. All Rights Reserved. © 2022 Better Solutions Limited Top