Two Laptop Bag*
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 Murach's Java Servlets and JSP this week in the Servlets 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: 1043
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: 60749
    
  65

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: 1043
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
 
Don't get me started about those stupid light bulbs.
 
subject: Can't instantiate simple class
 
Similar Threads
Need help: can't create stub using rmic
Trouble geting Solaris 1.3 JRE to work
Acessing external JNDI namespace
weird error
Tomcat 4.1.12, can't compile classes