How about aTextField.setCaretPosition(0); or am I missing something? Alternatively, you could create a new Document, put the text you'd like to see in there and then setDocument() on the text field, but that's a bit heavy handed. -----Original Message----- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]On Behalf Of Ralph Kar Sent: 06 March 2001 11:44 To: [EMAIL PROTECTED]; [EMAIL PROTECTED] Subject: how do I scroll to the beginning of the content in a JTextField Hi all, after putting text in a JTextField, which is longer then the width of the JTextField, I want to programmatically display the text from the very beginning, which means I need to scroll back to the beginning of the text. I tried setScrollOffset() and scrollRectToView(), but none of these seem to work correctly. Is it possile at all? Greetings, Ralph ------------------------------------------------ Ralph Kar | Software Developer | mailto:[EMAIL PROTECTED] RTS AG | http://www.rtsgroup.net ------------------------------------------------ _______________________________________________ Advanced-swing mailing list [EMAIL PROTECTED] http://eos.dk/mailman/listinfo/advanced-swing _______________________________________________ Advanced-swing mailing list [EMAIL PROTECTED] http://eos.dk/mailman/listinfo/advanced-swing
