This week's book giveaway is in the Big Data forum.
We're giving away four copies of Elasticsearch in Action and have Radu Gheorghe & Matthew Lee Hinman on-line!
See this thread for details.
The moose likes Beginning Java and the fly likes  package javax.mail does not exist Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login

Win a copy of Elasticsearch in Action this week in the Big Data forum!
JavaRanch » Java Forums » Java » Beginning Java
Bookmark " package javax.mail does not exist" Watch " package javax.mail does not exist" New topic

package javax.mail does not exist

Patrick Noah

Joined: Aug 22, 2011
Posts: 28
I put mail.jar and activation.jar in my CLASSPATH environment variable on winxp but when i compile my program I still get this error.
Jesper de Jong
Java Cowboy
Saloon Keeper

Joined: Aug 16, 2005
Posts: 14598

Are you sure they are in the classpath correctly?

What do you see when you type the command: echo %CLASSPATH%

Note that after changing environment variables in Windows (via Computer / Properties etc.), you have to close and re-open the command prompt window. It will not pick up changes to environment variables if you change them while the command prompt window is open.

What command exactly are you typing in to compile your code?

Java Beginners FAQ - JavaRanch SCJP FAQ - The Java Tutorial - Java SE 8 API documentation
I agree. Here's the link:
subject: package javax.mail does not exist