aspose file tools*
The moose likes Struts and the fly likes ServletException: BeanUtils.populate Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Frameworks » Struts
Bookmark "ServletException: BeanUtils.populate" Watch "ServletException: BeanUtils.populate" New topic
Author

ServletException: BeanUtils.populate

Hubert Pernegger
Ranch Hand

Joined: Apr 11, 2006
Posts: 49
hi,
can anybody tell me, why I get the following error message:



thank you very much
Merrill Higginson
Ranch Hand

Joined: Feb 15, 2005
Posts: 4864
You get this message when Struts is unable to map the data in the HTML form to the properties in your ActionForm bean. Make sure each of the properties on your bean is either a String or a boolean. Do you have any properties of type java.util.Date or other objects? That might cause this error. Also check to see that you have public getters and setter for each of your properties.


Merrill
Consultant, Sima Solutions
Hubert Pernegger
Ranch Hand

Joined: Apr 11, 2006
Posts: 49
hi merrill,
the properties of my bean are String and Integer...and yes I checked the getters and setters....
and I don't have java.util.Date and other things...
Hubert Pernegger
Ranch Hand

Joined: Apr 11, 2006
Posts: 49
jsp code:



function:



action


thanks
Merrill Higginson
Ranch Hand

Joined: Feb 15, 2005
Posts: 4864
A property of type Integer could still cause this error. If you want to keep internal representation of the property as an Integer, that's fine, but change the setter so that it accepts a String, and then convert it to an Integer.
Hubert Pernegger
Ranch Hand

Joined: Apr 11, 2006
Posts: 49
hi merril,
thanks a lot, you are right it worked that way
thank you very much, wish you a nice evening....

regards
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: ServletException: BeanUtils.populate