Getting the Text of a Text Field The method is getText(), and there is a variant to retrieve just the selected text:
Read Complete Article