• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

Cant Access JTextArea to append text

 
Greenhorn
Posts: 1
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hello Guys ,

I have parent JFrame which has some buttons , when I click button called scan . I crate the object for JDialog which contain text area which I cant print in. After I close the JDialog scan operation performs ! But I cant still print anything to even hello to my Dialog . Do i miss step here ? Please help !

I tried this.


public class Uitest extends javax.swing.JFrame {

public ScanResultsDialog sr;

private void ScanActionPerformed(java.awt.event.ActionEvent evt) {


sr = new ScanResultsDialog(Uitest.this , true);

}

}


My Dialog class ScanResultDialog with constructor which has text area called jtextarea1

public class ScanResultsDialog extends javax.swing.JDialog {



public ScanResultsDialog(java.awt.Frame parent, boolean modal) {

super(parent, modal);
initComponents();
this.setVisible(modal);

this.jtextarea1.sppend|("Hello");


}


Thanks

 
Rancher
Posts: 43081
77
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Welcome to JavaRanch.

What do you mean by "you can't print"? What exactly happens when you run this code? How is that different from what you were expecting?
 
Consider Paul's rocket mass heater.
reply
    Bookmark Topic Watch Topic
  • New Topic