Tapan Prajapati
,
Greenhorn
Mar 10, 2010 10:35:01
m use net bean and i want to print the data to text area but i only print them it in command prompt not in text area
Jeanne Boyarsky
,
author & internet detective
staff
Mar 10, 2010 16:24:29
This sounds like a Swing question since it is about outputting data to a JTextArea. Moving to our Swing forum.
Michael Dunn
,
Ranch Hand
Mar 10, 2010 17:27:54
you have in your code this:
System.out.println(name +"\t" + "-"+ phonenumber);
and this:
pw.println( name + "\t" + phonenumber);
and this:
recordTextArea.setText(phonenumber);
it seems you know how to access the textArea (unless this is not your code),
so just refer to the JTextArea apidocs for a method to add, or append (hint), text.
Tapan Prajapati
,
Greenhorn
Mar 10, 2010 20:16:52
ya but i had already define them in private field
now tell me what can i do
Michael Dunn
,
Ranch Hand
Mar 10, 2010 21:19:36
> now tell me what can i do
I already told you 'where' and 'what'.
if you want someone to write it for you, try rent-a-coder
Tapan Prajapati
,
Greenhorn
Mar 11, 2010 00:32:08
i don't know what you want to say , you reply if you know answer. i just want to print the database data to my text area that's all.
Michael Dunn
,
Ranch Hand
Mar 11, 2010 00:41:22
> you reply if you know answer.
I do, because I've read the documentation.
I even gave you a hint in my first reply.
Maneesh Godbole
,
Bartender
staff
Mar 11, 2010 00:54:17
Tapan,
Please use the quote button only when you want to quote something. For your own replies, please use the Post Reply button
Rob Spoor
,
Sheriff
staff
Mar 11, 2010 01:31:24
Tapan Prajapati wrote: i just want to print the database data to my text area that's all.
Have you even read Michael's first reply?
Michael Dunn wrote: so just refer to the JTextArea apidocs for a method to add, or append (hint), text.
Click on JTextArea if you don't know how to find the API docs.
This one time, at bandcamp, I had relations with a tiny ad.
a bit of art, as a gift, the permaculture playing cards
https://gardener-gift.com