So I have class A extends class B, class B extends JInternalFrame, B has a method myMethod (in my case myMethod converts an order system to decimal numbers). Now I want to use myMethod from class B in a method in class A, but when I try to call super.myMethod() it says myMethod() is not found, and when I took a look at all the methods that show up after typing "super.", the methods are all JTable methods (if I control click any method from the drop down I go to JTable.java).
I have tried creating a B in class A then use B.myMethod(), this works but is there a way to call myMethod in class A without making a B?
public class B extends JInternalFram{
constructor(){
}
public myMethod(){
//does conversions here
}
}
public class A extends B{
constructor(){
}
public anotherMethod(){
//needs to use b.myMethod();
}
}
Thanks