Win a copy of Cross-Platform Desktop Applications: Using Node, Electron, and NW.js this week in the JavaScript forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic

JTextArea  RSS feed

 
Andrew Lit
Ranch Hand
Posts: 135
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,
i'd like to know how to make textarea not editable for user, but it would be possible to edit it programaticaly.
Could you give me a hint.
i tried this code, but it is not working ( when i type in the text area listener seems not working )

Could you give a hint on this? thank you in advance
 
Gregg Bolinger
Ranch Hand
Posts: 15304
6
Chrome IntelliJ IDE Mac OS X
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Why don't you just use textarea.setEditable(false). You can still programmatically append, nove, change, remove, add text to the text area, but you can't just go in and type characters.
 
Andrew Lit
Ranch Hand
Posts: 135
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
well i feel a little bit silly.
thank you, didn't even think of that
[ June 20, 2003: Message edited by: Andrew Lit ]
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!