• Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

passing value from one class to another class(which extends JFrame)

 
abracadabration abracadabration
Greenhorn
Posts: 2
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
While passing a value from a method of class A to a method in class B, I must instantiate class B in A. But when dealing with swing programs, and when I create a reference for class B (which extends JFrame) in A, it again invocates the already invocated JFrame.

How can I solve this problem?

Is there a efficient way to pass value from one class to another class without invocating destine class constructor(apart from declaring the destine method "static")?
 
Ernest Friedman-Hill
author and iconoclast
Marshal
Pie
Posts: 24212
35
Chrome Eclipse IDE Mac OS X
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
You've already been told about the naming policy once; now I have to tell you about it again. You're required to use a first and last name, a real-sounding name, not gibberish. We want to feel like we're interacting with an adult person, not a robot or an eight-year-old. Real names, please. Until then, you'll find most people don't want to help you. Head back here, please, and try again.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic