Paragraph.EndPosition

From Xojo Documentation

Read-Only Property (As Integer )
IntegerValue = aParagraph.EndPosition

New in 2019r2

Supported for all project types and targets.

End position of the paragraph (1-based).

Example

Bold the last character of the text:

TextArea1.StyledText.Text = "Hello, World!"

// Bold the "!"
Var theEnd As Integer = TextArea1.StyledText.Paragraph(1).EndPositiion
TextArea1.StyledText.Bold(theEnd - 1, 1) = True