I am having trouble to run a client. Its a simple stand alone program accessing
EJB.
My EJB is deployed perfectly on weblogic 9.2 server with entry in the JNDI tree.
but i am not able to make my client run..
Following is the exception I am getting while running through console. It compiled perfectly with all necessary classes.
C:\Users\abhinav\workspace\EJBConverter\src\com\client>
java -cp .;c:\j2ee-1.4.jar; ConverterClient
Exception in
thread "main" java.lang.NoClassDefFoundError: ConverterClient (wrong name: com/client/ConverterClient)
at java.lang.ClassLoader.defineClass1(Native Method)
at java.lang.ClassLoader.defineClass(Unknown Source)
at java.security.SecureClassLoader.defineClass(Unknown Source)
at java.net.URLClassLoader.defineClass(Unknown Source)
at java.net.URLClassLoader.access$000(Unknown Source)
at java.net.URLClassLoader$1.run(Unknown Source)
at java.security.AccessController.doPrivileged(Native Method)
at java.net.URLClassLoader.findClass(Unknown Source)
at java.lang.ClassLoader.loadClass(Unknown Source)
at sun.misc.Launcher$AppClassLoader.loadClass(Unknown Source)
at java.lang.ClassLoader.loadClass(Unknown Source)
at java.lang.ClassLoader.loadClassInternal(Unknown Source)
Could not find the main class: ConverterClient. Program will exit.
Below is the client code: