You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@struts.apache.org by Miguel Angel Mulero Martinez <mi...@mad.tecsidel.es> on 2002/09/06 12:59:03 UTC

RE: ClassCastException:java.lang.Integer

You can show me the part of your JSP when you use the values?


-----Mensaje original-----
De: Vijeth R Naik [mailto:vijethr@ivega.com]
Enviado el: viernes, 06 de septiembre de 2002 12:59
Para: 'Strut User'
Asunto: ClassCastException:java.lang.Integer

Hi
I am a newbie using struts.
I have a simple jsp which has 2 fields, a String and a Number(eg: Name and
Age)<br>
When I try displaying the jsp, I get this exception,
ClassCastException:java.lang.Integer

I am using Tomcat-3.3.1 and Struts-1.0.2

I have a form bean, where "Name" is a String and "Age" is an int.

In my ActionClass, I  set the bean values..

String age_str=request.getParameter("age");
int age_int=(new Integer(age_str)).intValue();

beanClass.setAge(age_int);

Kindly let me know what is the error..


TIA

Vijeth



--
To unsubscribe, e-mail:
<ma...@jakarta.apache.org>
For additional commands, e-mail:
<ma...@jakarta.apache.org>


--
To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>