DesktopTextControl.SelectedText
From Xojo Documentation
Property (As String )
aDesktopTextControl.SelectedText = newStringValue
or
StringValue = aDesktopTextControl.SelectedText
New in 2021r3
Supported for all project types and targets.
or
StringValue = aDesktopTextControl.SelectedText
New in 2021r3
Supported for all project types and targets.
The currently selected text.
Example
This example places the selected text from a DesktopTextArea into a DesktopTextField.
TextArea1.SelectionStart = 0
TextArea1.SelectonLength = 10
TextField1.Text = TextArea1.SelectedText
TextArea1.SelectonLength = 10
TextField1.Text = TextArea1.SelectedText