• Post Reply Bookmark Topic Watch Topic
  • New Topic

printing multiple output  RSS feed

 
Shhailesh Joshi
Greenhorn
Posts: 26
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I am getting only one output printed on screen at last in GUI but it prints nicely on cmd.I am using NetBeans IDE.and Which Field, i.e TGextField,ComboBox,TextArea i have to select to plot or print that multiple outputs on sceen in GUI using NetBeans IDE.
 
Greg Brannon
Bartender
Posts: 563
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Check the API for the component being used to verify that the method exists (as in JTextArea), but try using the append() method rather than the setText() method. setText() overwrites what is already there while append() adds to what is already there. Don't forget to add the necessary returns/linefeeds to make the output look right.
 
Shhailesh Joshi
Greenhorn
Posts: 26
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
it works.thanks.
 
Shhailesh Joshi
Greenhorn
Posts: 26
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
hey can you help me in this also.i wrote a program to save an txt file.but it also overwrites the text.
 
Greg Brannon
Bartender
Posts: 563
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
A similar concept. You want to open the file for appending data to it rather than rewriting what's already there. Refer to the FileWriter API for the correct constructor.
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!