I want to call "setI" from class1. Can somone help me and show me what is wrong?
Java is treating MyPanel exactly like a JPanel, and won't let me create any new methods for it
However I need to be able to call custom (and non-static) methods from the class. Is this possible?
If not, any alternatives?
My MCRS certification:
Anyway, after some trial and error I managed to solve this by like this:
Joined: Jun 01, 2010
Whereas you created a MyGraphPanel, the variable graph is defined as a JPanel, which is fine because MyGraphPanel ISA JPanel. JPanel, however, does not have a setDrawValues() with the parameters that you specify.