Hi all, i have a variable in a JFRAME that i need to use in a JPANEL. How can i do that.
Example: MainProgram that launches Java Application.
Window1 that is a JFRAME
Window2 that is a JPANEL
In Window1 I have a variable declared example int X = 0; When the program runs int X is changed to 200. After the change I want that Window2 uses the same variable X that know it is 200 to draw a line.
Thanks