I have my project with the mail.jar in the lib folder. I created a manifest file as
Manifest-Version: 1.0
Main-Class: mainfile
Class-Path: lib/mail.jar
I then exported the jar file using eclipse.
I tried executing the jar file now as java -jar myjar.jar and I get the error
java.lang.NoClassDefFoundError: javax/mail/Address
Any pointers would be greatly appreciated
mail.jar in your class path.jar file, is all required jar are came there if not you have to use eclipse option Extract required libraries into generated JAR. If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With