We can cap the value of a text layer to a maximum character using time itself, how cool is that?
Using the value of an existing Text Layer
All we need to do is to remap time to the number of letters in our text. Apply the following expression to a Text Layer "Source Text" property
From global time to layer time
The effects seem to work just fine. However. the range we set with startAt and endAt is referring to the global comp time and ignores the layer start time. If the layer starts / ends outside the range we set in the expression head, you might not see the effect because it's taking place when the layer is not visible.
To fix this we can use "inPoint" in our expression to make up for the difference, like so:
inPoint is the time in seconds in which the layers start in the timeline. Adding it to our range will make the range relative to the layer itself. COOL!