I would recommend two buttons. One calls String.toUpperCase() and the other calls String.toLowerCase() on the text field's String value when pressed.