Posted on 2003-03-24
I am setting one private varaible in actionperformed method()
(i mean setting that varaible at run time )
in that class i have one method to print that variable which setted in actionperformed().
when i am using this print method in another class, it diplaying nullvalue.
can any body help me in this.
private String check=new String();
//create one button
JButton click=new JButton();
check="yes i got it";
public void printMethod()
} //end of first class
search src=new search("hello");
} // end of second class
1. if run the first program the check valueis set to " yes i got it".
2. if i run the secong program the check value is null
why it is happening.
if i want to get the check value through second class , what i ahve to do??