How do I access the variable within another class's method?
Important bits of the Main class:
Genster mechz =new Genster();
//...
privateclass ClickListenerimplements ActionListener{
publicvoid actionPerformed(ActionEvent e){
if (e.getSource() == b_generate){
if (basic.isSelected() ==true);{
Genster.BasicG();// to execute what would be in that method
t_generate.setText(/*what to put here?*/);
}
Genster class:
publicclass Genster{
publicstaticvoid BasicG(){
String numbercool ="1337, it worked!";
//return numbercool;
// Without the void, NetBeans complains that I don't have a
// return type, although I have it here, currently commented. Returning numbercool
// would seem logical. :/
}
}
So, I'm a bit stumped here. I want to set the text of a text box to what my BasicG method in Genster processes. Right now, it just assigns numbercool to something I specify. I've tried all sorts of things like mechz.numbercool and mechz.BasicG(numbercool) Help please! :D

