Characters "after" String length

Is there a way of determining the characters of a string after so many pixels? I’m using If .clientWidth > .scrollWidth to determine if it is bigger but would like to identify the characters in the string that are wider than .scrollWidth

The only way I can think of doing this is to add characters to the field one at a time, checking the clientWidth after each one.

1 Like