This week's book giveaway is in the OCAJP 8 forum. We're giving away four copies of OCA Java SE 8 Programmer I Study Guide and have Edward Finegan & Robert Liguori on-line! See this thread for details.
Hi, I made a few minor modifications to a erstwhile working applet and get the following error message : ... cannot resolve symbol symbol : variable search location : class java.awt.Panel PanelCliInfo.search.ActionListener(this); ... The complete applet is big, so here is the gist of it :
this is an innerclass problom .. change PanelCliInfo.search.addActionListener(this); // this DOES NOT WORK! to demoApplet.this.PanelCliInfo.search.addActionListener(this); this will work basha
Joined: Jul 29, 2002
Hi. Thanks for that, it compiles fine again.
However, when I try to run it after modifying and recompiling, I get this unusual runtime error on the java console :
When I re-instate the original applet without the inner panel p2, it works fine again and does not throw the NullPointer Exception ! The error message is too cryptic for me to begin debugging it. Nice Chrissy treat from JAVA. Can you please explain the theory behind the "inner class" to me ? It would be nice to understand wy it compiles.
THX Merry Christmas .
[ December 25, 2002: Message edited by: achana chan ]
Joined: Jan 18, 2002
u made a varible for ClientInfo twice and assigned object to local variable.that's the problm.. u can resolve like this, change Panel PanelCliInfo = new ClientInfo();//in init() method to PanelCliInfo = new ClientInfo(); that's all basha