Go Back   TechArena Community > Software > Software Development
Become a Member!
Forgot your username/password?
Tags Active Topics RSS Search Mark Forums Read

Reply
 
Thread Tools Search this Thread
  #1  
Old 17-03-2010
Member
 
Join Date: Mar 2010
Posts: 3
JTextArea for input text from the user

Hi,
I try to create a JTextArea that the user enters text to it, and I would like to use this text, when the user presses a button.
textArea.getText() gives me the original text, its like it is not updated even though in the gui, the text the user entered is shown.
How can I get the inserted text?

Thanks a lot,
Liat
Reply With Quote
  #2  
Old 17-03-2010
Member
 
Join Date: Jan 2008
Posts: 1,515
Re: JTextArea for input text from the user

You have to use Text Areas in the following ways.
The JTextArea class provides a component that displays multiple lines of text and optionally allows the user to edit the text. If you need to obtain only one line of input from the user, you should use a text field. If you want the text area to display its text using multiple fonts or other styles, you should use an editor pane or text pane. If the displayed text has a limited length and is never edited by the user, use a label.
Reply With Quote
Reply

  TechArena Community > Software > Software Development
Tags: , , ,



Thread Tools Search this Thread
Search this Thread:

Advanced Search


Similar Threads for: "JTextArea for input text from the user"
Thread Thread Starter Forum Replies Last Post
Input text value problem NetworkeR Software Development 3 28-11-2009 11:56 AM
Check multiple text box input GlassFish Software Development 2 24-11-2009 01:23 PM
Setting input text values Solaris Software Development 3 23-11-2009 02:42 PM
Bolding text in a JTextArea Kieran Blenkarne Software Development 3 09-11-2009 01:10 PM


All times are GMT +5.5. The time now is 07:00 PM.