Very simple test code:
application.output(elements.letterText.caretPosition);
run from a button on the same form as letterText.
Select empty letterText in a new record, type “abc”, and push the button; the script outputs 0! Return to letterText and click after the “c”; the script outputs 3.0. The on-screen caret is in the same place (after the “c”) in both cases but the result is different. Perhaps caretPosition isn’t updated correctly as you type?
Help please.