aspose file tools*
The moose likes Other JSE/JEE APIs and the fly likes Facing problem to send mail using javamail api without authentication Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Java » Other JSE/JEE APIs
Bookmark "Facing problem to send mail using javamail api without authentication" Watch "Facing problem to send mail using javamail api without authentication" New topic
Author

Facing problem to send mail using javamail api without authentication

dhaval thakor
Ranch Hand

Joined: Aug 27, 2012
Posts: 53



According code given above i am getting following error . please help me to solve this problem.
Paul Clapham
Bartender

Joined: Oct 14, 2005
Posts: 18570
    
    8

Yet another reason why you shouldn't put Java code in a JSP. Based on the compiler message, it appears that the variable named "session" has already been declared. Either you did that, or (more likely) the "session" variable is one which is built into every JSP.

The straightforward solution would of course be to just call your "session" variable something else. But the proper solution would be to take that code out of the JSP entirely and put it in a servlet, or a helper class, or some other Java class.
 
Don't get me started about those stupid light bulbs.
 
subject: Facing problem to send mail using javamail api without authentication