Java Mailing List Archive

http://www.junlu.com/

Google
Google
Mailing List
Home
Forum Home
JBoss - Java Application Server
Struts - A MVC web framework
Tomcat - JSP/Servlet container
iText - An open source PDF Java Library
JDOM - JDOM XML Parser
J2EE - A mailing list for Java(tm) 2 Platform, Enterprise Edition
J2EE Pattern - An interest list for Sun Java Center J2EE Pattern Catalog
Servlet - A mailing list for discussion about Sun Microsystem's Java Servlet API Technology
JSP - A mailing list about Java Server Pages specification and reference
Struts & Hibernate
Subjects
JSP editor plugin for eclipse ?
org apache jasper JasperException: Unable to compile class for JSP
Tomcat: Connection reset by peer: socket write error
Cannot retrieve definition for form bean null
Struts Tiles Tutorial (free Struts training)
Where do I download Tomcat 4 0 6?
Data Access Object (DAO) pattern, example DAO 's
Where to download Tomcat v 4 1 24 from?
Tomcat 5 0 16 Requested resource not available
Oracle Connection Pooling in 3 2 2
Servlet : Session invalidate
Servlet action is currently unavailable
Tomcat/Struts Unicode Encoding/Decoding problems
Tomcat and webapplication specific java library path
Running a Simple JMS Example
Mapping in workers2 properties
org apache jasper JasperException
Cannot find message resources under key org apache struts action
   MESSAGE
problem with html:text bean throwing exception
Cannot find message resources under key org apache struts action MESSAGE
invalid direct reference problem with solution
Tool for jsp debug Try Sysdeo Eclipse Plugin
Tomcat 5 Cannot load JDBC driver class 'null ' SQL state: null
weblogic ejbc
java properties file
Jboss 3 2 3 Coyote Can 't re
Tomcat 5, Apache2 and mod jk2 integration problem
JBoss example problem new to J2EE
url string for connecting jboss to oracle
Value attribute of <html:checkbox
javax servlet ServletException: BeanUtils populate
HTTP Status 404 The requested resource is not available
5 0 18: Windows XP Pro vs Windows 2000
 
Need help to send email with servlet

Need help to send email with servlet

2004-01-05       - By Lambok Sianturi

 Back
Reply:     1     2     3     4  

Hi all,
i try to copy the servlet for sending email from Tomcat 4.0.4 example and use
it in our company technical support web application.
I have also add the
<resource-ref>
     <res-ref-name>mail/Session</res-ref-name>
     <res-type>javax.mail.Session Source code of javax.mail.Session</res-type>
     <res-auth>Container</res-auth>
   </resource-ref>
portion into the web.xml file.

But when trying to running the send mail servlet i got this exception.
   javax.naming.NameNotFoundException Source code of javax.naming.NameNotFoundException: Name java:comp is not bound in this
Context
But sending email from the Tomcat example page itself is ok. Have i missed
something? Would anyone give any suggestion?
Thanks in advance.

l a m b o k s i a n t u r i
- i t   s t a f f -
pt. multi garmenjaya
j l .  k r a w a n g   n o 1
b a n d u n g  -  i n d o n e s i a

__ ____ ____ ____ ____ ____ ____ ____ ____ ____ ____ ____ ____ ____ ____ __
To unsubscribe, send email to listserv@(protected) and include in the body
of the message "signoff SERVLET-INTEREST".

Archives: http://archives.java.sun.com/archives/servlet-interest.html
Resources: http://java.sun.com/products/servlet/external-resources.html
LISTSERV Help: http://www.lsoft.com/manuals/user/user.html

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML><HEAD>
<META http-equiv=Content-Type content="text/html; charset=iso-8859 (See http://iso-8859.ora-code.com)-1">
<META content="MSHTML 6.00.2800.1106" name=GENERATOR>
<STYLE></STYLE>
</HEAD>
<BODY bgColor=#ffffff>
<DIV><FONT face=Arial size=2>Hi all,</FONT></DIV>
<DIV><FONT face=Arial size=2>i try to copy the servlet for sending email from
Tomcat 4.0.4 example and use it in&nbsp;our company&nbsp;technical support web
application. </FONT></DIV>
<DIV><FONT face=Arial size=2>I have also add the</FONT></DIV>
<DIV><FONT face="Courier New"
size=2>&lt;resource-ref&gt;<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
&lt;res-ref-name&gt;mail/Session&lt;/res-ref-name&gt;<BR>&nbsp;&nbsp;&nbsp;
&nbsp;&nbsp;
&lt;res-type&gt;javax.mail.Session Source code of javax.mail.Session&lt;/res-type&gt;<BR>&nbsp;&nbsp;&nbsp;&nbsp;
&nbsp;
&lt;res-auth&gt;Container&lt;/res-auth&gt;<BR>&nbsp;&nbsp;&nbsp;
&lt;/resource-ref&gt;</FONT></DIV>
<DIV><FONT face="Courier New" size=2><FONT face=Arial>portion into
the</FONT><FONT face="Courier New"> web.xml file.</FONT></FONT></DIV>
<DIV>&nbsp;</DIV>
<DIV><FONT face=Arial size=2>But when trying to running the send mail servlet i
got this exception.</FONT></DIV>
<DIV><FONT face="Courier New" size=2>&nbsp;&nbsp;&nbsp;
javax.naming.NameNotFoundException Source code of javax.naming.NameNotFoundException: Name java:comp is not bound in this
Context</FONT></DIV>
<DIV><FONT face=Arial size=2>But sending email from the Tomcat example page
itself is ok. Have i missed something? Would anyone give any
suggestion?</FONT></DIV>
<DIV><FONT face=Arial size=2>Thanks in advance.</FONT></DIV>
<DIV><FONT face=Arial size=2></FONT>&nbsp;</DIV>
<DIV><FONT face=Arial size=2>l a m b o k s i a n t u r i<BR>- i t&nbsp;&nbsp; s
t a f f -<BR>pt. multi garmenjaya<BR>j l .&nbsp; k r a w a n g&nbsp;&nbsp; n o
1<BR>b a n d u n g&nbsp; - &nbsp;i n d o n e s i a</FONT></DIV></BODY></HTML>
__ ____ ____ ____ ____ ____ ____ ____ ____ ____ ____ ____ ____ ____ ____ __
To unsubscribe, send email to listserv@(protected) and include in the body
of the message "signoff SERVLET-INTEREST".
<p>
Archives: http://archives.java.sun.com/archives/servlet-interest.html
Resources: http://java.sun.com/products/servlet/external-resources.html
LISTSERV Help: http://www.lsoft.com/manuals/user/user.html
<p>

©2008 junlu.com - Jax Systems, LLC, U.S.A.