TEXTWIDTH function
Returns the width of the composed text in a shape.
Syntax
TEXTWIDTH(shapename!TheText,maximumwidth) | |
shapename! |
A name that refers to the text of a shape other than the current shape. Default equals the current shape. |
TheText |
A cell that gets triggered when the associated shape's text composition changes. |
maximumwidth |
Optional. The maximum width of the text block. |
Remarks
The TEXTWIDTH function is commonly used to adjust the width of a shape to fit the text it contains.
If maximumwidth is specified, the result is the longest line of text that fits within maximumwidth. If maximumwidth is omitted, the result is the total width of the text.
Example
TEXTWIDTH(TheText)
Returns the total length of the text in the current shape.