File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
The moose likes JSP and the fly likes Can't instantiate simple class Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Soft Skills this week in the Jobs Discussion forum!
JavaRanch » Java Forums » Java » JSP
Bookmark "Can Watch "Can New topic
Author

Can't instantiate simple class

Mike London
Ranch Hand

Joined: Jul 12, 2002
Posts: 1083
This is probably simple, but I'm trying to instantiate a class that sends an email, but I'm getting this error in my JSP when I'm trying to instantiate the class.

root cause: java.lang.NoClassDefFoundError: javax/mail/MessagingException

This error above refers, I think, to my "import javax.mail.MessagingException" line of code in the SendEmail class.

I believe my problem is that I'm missing a required library on the server since this SendEmail class works fine locally, but it's not clear which library I need to add to the server.

Can anyone please suggest what I'm missing?

Thanks very much in advance.

-- Mike
Bear Bibeault
Author and ninkuma
Marshal

Joined: Jan 10, 2002
Posts: 61761
    
  67

The JavaMail api. You need to obtain it from the Sun site.


[Asking smart questions] [Bear's FrontMan] [About Bear] [Books by Bear]
Mike London
Ranch Hand

Joined: Jul 12, 2002
Posts: 1083
Thanks.
Isuru Sampath
Ranch Hand

Joined: Jun 26, 2003
Posts: 57
Originally posted by Bear Bibeault:
The JavaMail api. You need to obtain it from the Sun site.


and place it in the


directory.


No Winds No Waves
 
Consider Paul's rocket mass heater.
 
subject: Can't instantiate simple class