Hello,
I have a simple
Java class that sends an email when run. It works fine when run from within the
IDE.
However, when I try to run the same code from the command line, I get this error stack:
Exception in
thread "main" java.lang.NoClassDefFoundError: javax/mail/internet/AddressException
Caused by: java.lang.ClassNotFoundException: javax.mail.internet.AddressException
at java.net.URLClassLoader$1.run(URLClassLoader.java:202)
at java.security.AccessController.doPrivileged(Native Method)
at java.net.URLClassLoader.findClass(URLClassLoader.java:190)
at java.lang.ClassLoader.loadClass(ClassLoader.java:307)
at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:301)
at java.lang.ClassLoader.loadClass(ClassLoader.java:248)
(Huh?)
The AddressException is fully referenced in the catch clause and no errors (missing imports) are noted. (Again, this code runs perfectly when run from within the IDE.)
Any ideas why the same code that works fine from the IDE does not work when run from the command line?
Thanks in advance for any help or suggestions.
mike