This week's book giveaway is in the Agile and other Processes forum.
We're giving away four copies of The Mikado Method and have Ola Ellnestam and Daniel Brolund on-line!
See this thread for details.
The moose likes Beginning Java and the fly likes multiline textfield Big Moose Saloon
  Search | Java FAQ | Recent Topics
Register / Login


Win a copy of The Mikado Method this week in the Agile and other Processes forum!
JavaRanch » Java Forums » Java » Beginning Java
Reply Bookmark "multiline textfield" Watch "multiline textfield" New topic
Author

multiline textfield

Annalisa Annalisa
Greenhorn

Joined: Mar 07, 2005
Posts: 6
How can I specify a text field (JTExtField) as multiline? I mean that the user input doesn't expand horizontally but it automatically goes down a line?

Thank you
Annalisa
James Carman
Ranch Hand

Joined: Feb 20, 2001
Posts: 580
You can't! Use JTextArea instead.


James Carman, President<br />Carman Consulting, Inc.
Ray Stojonic
Ranch Hand

Joined: Aug 08, 2003
Posts: 326
The first line of the JTextField documentation reads: "JTextField is a lightweight component that allows the editing of a single line of text."

What you want is a JTextArea
Annalisa Annalisa
Greenhorn

Joined: Mar 07, 2005
Posts: 6
ok..sorry! :roll:
thank you
 
I agree. Here's the link: http://ej-technologies/jprofiler - if it wasn't for jprofiler, we would need to run our stuff on 16 servers instead of 3.
 
subject: multiline textfield
 
Similar Threads
JSP radio buttons Multi line text box
How to search a pattern in a large file using java
Multiline Strings
JTable/Column modification
JTable/Column modification /urgent