Dear Ranchers, I am trying to run AdviceClient and i am getting the below exception.
java.lang.ClassCastException at com.sun.corba.se.internal.javax.rmi.PortableRemoteObject.narrow(Unknown Source) at javax.rmi.PortableRemoteObject.narrow(Unknown Source) at AdviceClient.go(AdviceClient.java:24) at AdviceClient.main(AdviceClient.java:11)
I have done all possible things. I have j2ee.jar in the classpath and the client jar also in the classpath. I tried to find it in the google but with little vain. I am using j2ee 1.4 server and Operating system is Windows XP.
Hi Shivakanth Make sure that the class type which you pass as an argument to the narrow method is of the same type as the home interface and that the cast is being made to that same home type. Also, make sure that the home is not local.
SCJP 1.4, SCWCD 1.4, SCBCD 1.3, SCJD, SCEA/OCMJEA
Live life to an interface, not an implementation!
Joined: Mar 28, 2005
I could solve this we need to add one more jar file in the CLASSPATH and it works.