How do I change the text in a Text Shape dynamically?

MAXScript Frequently Asked Questions

Normally, the text of a Text shape is not animatable. The resulting mesh will be evaluated once at the beginning of the rendering and will not change as it is considered static (not changing over time). A workaround is to assign a script controller to a property of the text shape which will do two things: tell the renderer that the text shape is animated and thus requires reevaluation on each frame, and set the actual text in the text property.


Changing the text object's text property in anything other than a controller applied to the text object can lead to a renderer crash!


b=box name:"ControlBox" wirecolor:blue

t=text name:"ControlledText" wirecolor:red





as string\n0"


animate on at time 100 b.height*=2

max tool zoomextents all



See also

Frequently Asked Questions