• Post Reply Bookmark Topic Watch Topic
  • New Topic

JTextArea

 
smitham kumar
Greenhorn
Posts: 8
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hello all,

I wanted to know if it is possible to restrict the text that is entered in a JTextArea component.

I mean allow user to enter only 100 letters or may be only 10 lines in that area available

Thanks a lot in advance

regards
smitha
 
Saket Barve
Ranch Hand
Posts: 229
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Consider writing an InputVerifier for your JTextField, which will perform the required action.
 
Craig Wood
Ranch Hand
Posts: 1535
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Implementing a Document Filter
 
smitham kumar
Greenhorn
Posts: 8
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Thank you guys.. for your help..

regards,
shwetha
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!