Hey guys !
I am wondering is it possible for a, JTextArea to be editable in a JFrame also visible?
I mean, I have an application that will read in txt files and put the content to the TextArea, also I want it to be editable so I can save it later again.
Now my current question, with bufferedreader can I read in text files and then add them to JTextAreas, I haven't been able to do it; so asking if anyone here at C.C have done it and would like to share the knowledge !
Cheers !
Is it possible, anyone show a demo of it?
Started by Turk4n, May 06 2009 10:17 PM
6 replies to this topic
#1
Posted 06 May 2009 - 10:17 PM
|
|
|
#2
Posted 07 May 2009 - 09:40 AM
Pretty sure thats possible.
Why are you having trouble putting a String in a textarea?
Why are you having trouble putting a String in a textarea?
#3
Posted 07 May 2009 - 10:36 PM
Stu_328 said:
Pretty sure thats possible.
Why are you having trouble putting a String in a textarea?
Why are you having trouble putting a String in a textarea?
Not really, I have the problem to read in textfiles and add them up in the textarea, making it simple to be edited and saved. I have the opening/saving functions ready; but not the textfile to textarea link(does not compute !)
#4
Posted 09 May 2009 - 02:52 AM
open the text file. Read it in (as a whole or line by line) and put it in the text area using insert().
#5
Posted 09 May 2009 - 04:41 AM
Stu_328 said:
open the text file. Read it in (as a whole or line by line) and put it in the text area using insert().
Did not work :-(
#6
Posted 09 May 2009 - 05:55 AM
It does work, I've just done it.
textArea.insert("stuff",0);
#7
Posted 18 May 2009 - 10:24 AM
are you closing your buffered reader?


Sign In
Create Account


Back to top









