• Post Reply Bookmark Topic Watch Topic
  • New Topic

run of of memory in JTextArea  RSS feed

 
Marcus Hoe
Greenhorn
Posts: 14
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
As my program keeps running and append text to the JTextArea, it soon throws "out of memory" exception. So how do i tackle this problem without setting the text to "". Coz i still want to retain the history, maybe just delete half.
 
Michael Szul
Ranch Hand
Posts: 57
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I'm not positive about this because I've never ran out of memory, but maybe you should try a JTextPane or JEditorPane instead of a JTextArea, which is pretty limited.
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!