You will have another error for your usebean tag: it should end with /> instead of >
Tom -----Original Message----- From: Antony Paul [mailto:[EMAIL PROTECTED] Sent: jeudi 23 septembre 2004 13:59 To: Tomcat Users List Subject: Re: small but complex problem -jsp.error.badaction when accessing a bean from a jsp The problem is at line number 5. org.apache.jasper.JasperException: /idcard.jsp(5,5) jsp.error.badaction You forgot to put % sign. <body> ////<@page import="com.dinesh.idcard" > <% @page import="com.dinesh.idcard" %> <jsp:usebean id="myidcard" scope="page" class="com.dinesh.idcard"> rgds Antony Paul ----- Original Message ----- From: "Dinesh Keesara" <[EMAIL PROTECTED]> To: <[EMAIL PROTECTED]> Sent: Thursday, September 23, 2004 4:42 PM Subject: small but complex problem -jsp.error.badaction when accessing a bean from a jsp > > > > Hey can anyone solve this ...... > > I am using Tomcat 4.1.30 on IE > I am Getting following error : > > HTTP Status 500 - > ------------------------------------------------------------------------ -- ------ > type Exception report > message description > The server encountered an internal error () that prevented it from > fulfilling this request. > exception > org.apache.jasper.JasperException: /idcard.jsp(5,5) jsp.error.badaction > at > org.apache.jasper.compiler.DefaultErrorHandler.jspError(DefaultErrorHand ler. java:94) > at > org.apache.jasper.compiler.ErrorDispatcher.dispatch(ErrorDispatcher.java :428 ) > at > org.apache.jasper.compiler.ErrorDispatcher.jspError(ErrorDispatcher.java :126 ) > at org.apache.jasper.compiler.Parser.parseAction(Parser.java:671) > at org.apache.jasper.compiler.Parser.parseElements(Parser.java:803) > at org.apache.jasper.compiler.Parser.parse(Parser.java:122) > > and blah blah blah .......... > > the jsp file looks as follows: > > <html> > <head> > </head> > <body> > <@page import="com.dinesh.idcard" > > <jsp:usebean id="myidcard" scope="page" class="com.dinesh.idcard"> > <jsp:setProperty name="myidcard" property="RollNo" value="123" /> > <jsp:setProperty name="myidcard" property="Name" value="Harikiran" /> > </jsp:usebean> > <%=myidcard.getName()%> > <br> > <%=myidcard.getRollNo()%> > </body> > </html> > > and the bean file looks as follows: > > package com.dinesh; > public class idcard{ > private int RollNo; > private String Name; > public void setRollNo(int num){ > this.RollNo=num; > } > public int getRollNo(){ > return RollNo; > } > public void setName(String Name) > { > this.Name=Name; > > _________________________________________________________________ > The new MSN toolbar! Your shortcut to the internet! > http://toolbar.msn.co.in/ Access a world of convenience! > > > --------------------------------------------------------------------- > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > > --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
