0

I have two Java Swing classes. I want to put extra some String in second Swing GUI on button click. I wrote code to can show second JFrame, but I don't know how to put some data (name, last name or etc).

This is my button listener code:

DetailsGUI detailsGUI=new DetailsGUI();
detailsGUI.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
detailsGUI.pack();
detailsGUI.setVisible(true);

How can I solve this problem?

Andrew Thompson
  • 168,117
  • 40
  • 217
  • 433
BekaKK
  • 2,173
  • 6
  • 42
  • 80

0 Answers0