Ver Mensaje Individual
  #9 (permalink)  
Antiguo 18/07/2013, 07:23
Avatar de JDEM
JDEM
 
Fecha de Ingreso: octubre-2008
Ubicación: www....
Mensajes: 154
Antigüedad: 16 años, 3 meses
Puntos: 8
Respuesta: Configurar envió de correos con javamail en tomcat 6

Saludos bro, ahora el servidor me responde lo siguiente:

Cita:
org.apache.jasper.JasperException: Unable to compile class for JSP:

An error occurred at line: 6 in the generated java file
Syntax error on token ";", import expected after this token

An error occurred at line: 6 in the generated java file
Syntax error on token ";", import expected after this token

An error occurred at line: 10 in the jsp file: /mail.jsp
Syntax error on token(s), misplaced construct(s)
7:
8: String smtpHost = "mail.dominio.com";
9: Properties props = System.getProperties();
10: props.put("mail.smtp.host",smtpHost);
11:
12: Session sesion = Session.getDefaultInstance(props,null);
13: try {


An error occurred at line: 10 in the jsp file: /mail.jsp
Syntax error on token ""mail.smtp.host"", invalid FormalParameterList
7:
8: String smtpHost = "mail.dominio.com";
9: Properties props = System.getProperties();
10: props.put("mail.smtp.host",smtpHost);
11:
12: Session sesion = Session.getDefaultInstance(props,null);
13: try {


An error occurred at line: 10 in the jsp file: /mail.jsp
Syntax error on token "smtpHost", VariableDeclaratorId expected after this token
7:
8: String smtpHost = "mail.dominio.com";
9: Properties props = System.getProperties();
10: props.put("mail.smtp.host",smtpHost);
11:
12: Session sesion = Session.getDefaultInstance(props,null);
13: try {


An error occurred at line: 12 in the jsp file: /mail.jsp
Session cannot be resolved to a type
9: Properties props = System.getProperties();
10: props.put("mail.smtp.host",smtpHost);
11:
12: Session sesion = Session.getDefaultInstance(props,null);
13: try {
14: Message mensaje = new MimeMessage(sesion);
15: mensaje.setSubject("Hola Mundo");


An error occurred at line: 12 in the jsp file: /mail.jsp
Session cannot be resolved
9: Properties props = System.getProperties();
10: props.put("mail.smtp.host",smtpHost);
11:
12: Session sesion = Session.getDefaultInstance(props,null);
13: try {
14: Message mensaje = new MimeMessage(sesion);
15: mensaje.setSubject("Hola Mundo");


An error occurred at line: 12 in the jsp file: /mail.jsp
Syntax error on token ";", { expected after this token
9: Properties props = System.getProperties();
10: props.put("mail.smtp.host",smtpHost);
11:
12: Session sesion = Session.getDefaultInstance(props,null);
13: try {
14: Message mensaje = new MimeMessage(sesion);
15: mensaje.setSubject("Hola Mundo");


An error occurred at line: 13 in the jsp file: /mail.jsp
Syntax error on token(s), misplaced construct(s)
10: props.put("mail.smtp.host",smtpHost);
11:
12: Session sesion = Session.getDefaultInstance(props,null);
13: try {
14: Message mensaje = new MimeMessage(sesion);
15: mensaje.setSubject("Hola Mundo");
16: mensaje.setFrom(new InternetAddress(from));


An error occurred at line: 14 in the jsp file: /mail.jsp
Message cannot be resolved to a type
11:
12: Session sesion = Session.getDefaultInstance(props,null);
13: try {
14: Message mensaje = new MimeMessage(sesion);
15: mensaje.setSubject("Hola Mundo");
16: mensaje.setFrom(new InternetAddress(from));
17: mensaje.addRecipient(Message.RecipientType.TO, new InternetAddress(to));


An error occurred at line: 14 in the jsp file: /mail.jsp
MimeMessage cannot be resolved to a type
11:
12: Session sesion = Session.getDefaultInstance(props,null);
13: try {
14: Message mensaje = new MimeMessage(sesion);
15: mensaje.setSubject("Hola Mundo");
16: mensaje.setFrom(new InternetAddress(from));
17: mensaje.addRecipient(Message.RecipientType.TO, new InternetAddress(to));


An error occurred at line: 14 in the jsp file: /mail.jsp
sesion cannot be resolved
11:
12: Session sesion = Session.getDefaultInstance(props,null);
13: try {
14: Message mensaje = new MimeMessage(sesion);
15: mensaje.setSubject("Hola Mundo");
16: mensaje.setFrom(new InternetAddress(from));
17: mensaje.addRecipient(Message.RecipientType.TO, new InternetAddress(to));


An error occurred at line: 16 in the jsp file: /mail.jsp
InternetAddress cannot be resolved to a type
13: try {
14: Message mensaje = new MimeMessage(sesion);
15: mensaje.setSubject("Hola Mundo");
16: mensaje.setFrom(new InternetAddress(from));
17: mensaje.addRecipient(Message.RecipientType.TO, new InternetAddress(to));
18: mensaje.setText("Este es el cuerpo del mensaje");
19: Transport.send(mensaje);


An error occurred at line: 17 in the jsp file: /mail.jsp
Message.RecipientType.TO cannot be resolved to a type
14: Message mensaje = new MimeMessage(sesion);
15: mensaje.setSubject("Hola Mundo");
16: mensaje.setFrom(new InternetAddress(from));
17: mensaje.addRecipient(Message.RecipientType.TO, new InternetAddress(to));
18: mensaje.setText("Este es el cuerpo del mensaje");
19: Transport.send(mensaje);
20: } catch(MessagingException e) {


An error occurred at line: 17 in the jsp file: /mail.jsp
InternetAddress cannot be resolved to a type
14: Message mensaje = new MimeMessage(sesion);
15: mensaje.setSubject("Hola Mundo");
16: mensaje.setFrom(new InternetAddress(from));
17: mensaje.addRecipient(Message.RecipientType.TO, new InternetAddress(to));
18: mensaje.setText("Este es el cuerpo del mensaje");
19: Transport.send(mensaje);
20: } catch(MessagingException e) {


An error occurred at line: 19 in the jsp file: /mail.jsp
Transport cannot be resolved
16: mensaje.setFrom(new InternetAddress(from));
17: mensaje.addRecipient(Message.RecipientType.TO, new InternetAddress(to));
18: mensaje.setText("Este es el cuerpo del mensaje");
19: Transport.send(mensaje);
20: } catch(MessagingException e) {
21: System.err.println(e.getMessage());
22: }


An error occurred at line: 20 in the jsp file: /mail.jsp
MessagingException cannot be resolved to a type
17: mensaje.addRecipient(Message.RecipientType.TO, new InternetAddress(to));
18: mensaje.setText("Este es el cuerpo del mensaje");
19: Transport.send(mensaje);
20: } catch(MessagingException e) {
21: System.err.println(e.getMessage());
22: }
23: %>


An error occurred at line: 21 in the jsp file: /mail.jsp
e cannot be resolved
18: mensaje.setText("Este es el cuerpo del mensaje");
19: Transport.send(mensaje);
20: } catch(MessagingException e) {
21: System.err.println(e.getMessage());
22: }
23: %>


An error occurred at line: 39 in the generated java file
Syntax error on token "Object", @ expected

Stacktrace:
org.apache.jasper.compiler.DefaultErrorHandler.jav acError(DefaultErrorHandler.java:92)
org.apache.jasper.compiler.ErrorDispatcher.javacEr ror(ErrorDispatcher.java:330)
org.apache.jasper.compiler.JDTCompiler.generateCla ss(JDTCompiler.java:439)
org.apache.jasper.compiler.Compiler.compile(Compil er.java:334)
org.apache.jasper.compiler.Compiler.compile(Compil er.java:312)
org.apache.jasper.compiler.Compiler.compile(Compil er.java:299)
org.apache.jasper.JspCompilationContext.compile(Js pCompilationContext.java:589)
org.apache.jasper.servlet.JspServletWrapper.servic e(JspServletWrapper.java:317)
org.apache.jasper.servlet.JspServlet.serviceJspFil e(JspServlet.java:313)
org.apache.jasper.servlet.JspServlet.service(JspSe rvlet.java:260)
javax.servlet.http.HttpServlet.service(HttpServlet .java:717)
note The full stack trace of the root cause is available in the Apache Tomcat/6.0.24 logs.
__________________
Visitanos http://www.nestsystems.com.ve, mucho mas que solo paginas web.