Character.FromNumber

Text

Returns the Unicode character corresponding to the given numeric code point.

Examples on this page use shared sample tables. View them to understand the input data before reading the examples below.

Syntax

Character.FromNumber(number as number) as text

Parameters

NameTypeRequiredDescription
numbernumberYesA Unicode code point number (e.g., 65 for "A").

Return Value

textA single-character text value corresponding to the Unicode code point.

Remarks

Character.FromNumber converts a Unicode code point (a non-negative integer) into the corresponding single-character text value. This is the inverse of Character.ToNumber. Any valid Unicode scalar value is accepted — the function is not limited to ASCII.

Common code point ranges include: - 0–31: Control characters (tab = 9, line feed = 10, carriage return = 13) - 32: Space - 48–57: Digits 09 - 65–90: Uppercase letters AZ - 97–122: Lowercase letters az

The most practical use of this function is programmatic character generation: building separator strings, inserting control characters such as line feeds or tabs into text output, or generating sequences of characters with List.Transform. For example, List.Transform({65..90}, Character.FromNumber) produces the full uppercase alphabet as a list without hard-coding any characters.

When working with control characters in text, be aware that Text.Clean removes non-printable characters (code points 0–31), while Text.Trim only removes leading and trailing whitespace. If you insert control characters using Character.FromNumber and later need to remove them, use Text.Clean.

Examples

Example 1: Convert a code point to its character

Character.FromNumber(65)
Result
Result
1A

Example 2: Generate a line feed character for text output

"Line 1" & Character.FromNumber(10) & "Line 2"
Result
Result
1Line 1 Line 2

Example 3: Build the full uppercase alphabet as a list

List.Transform({65..90}, Character.FromNumber)
Result
Result
1A,B,C,D,E,F,G,H,I,J,K,L,M,N,O,P,Q,R,S,T,U,V,W,X,Y,Z

Compatibility

Power BI Desktop Power BI Service Excel Desktop Excel Online Dataflows Fabric Notebooks