TEXTCENTER
centers text with padding to reach specified length · a deepcalc original · no excel equivalent · no sheets equivalent
signature
TEXTCENTER(text, length, [pad_char])
returns: text
| argument | required |
|---|---|
| text | required |
| length | required |
| pad_char | optional |
examples
formula and result, taken from the engine's own test suite — every result below is asserted in CI, not written by hand.
fx
=TEXTCENTER("hello", 11, "-") ---hello--- | A | |
|---|---|
| 1 | 10 |
fx
=TEXTCENTER(A1, 20) 10