im new here an would say HELLOOO to everyone
So ive got an issue.
I am creating in "class A" tabs for a JTabbedPane. In "class B" i create the JTabbedPane and creat instances of class A and add them to the TabbedPane.
in Class B i also create a button, for save actions. When i click the button, a method "save()" will be called and read from every tab the Strings out of textfields.
My problem now is, that it dont work, i call the save method with the instance from the tab, but it dont getText() from the textfield.
//create an instance tab, parameter is the save file
Tab myTab = new Tab(file);
(Tab)myTab.save(); //here i eclipse cast to Tab automatically
the save-Method in class A (Tab):
BTW how can i highlight code in this forum?
You can add syntax highlighting by going into the advanced editor, that will add a button for it. Unfortunately there are no quick code tags :/
After you find the button post your ACTUAL code. not just some random snippet which looks like your code. What you posted doesn't even compile.