tags:

views:

49

answers:

2

Hi, I have a struts app with a jsp with the code:

...

...
<input name="inrofol" class="inputfilter" id="inrofol" size="22" maxlength="20" type="text">
...

And even though it's not linked to the associated form bean, I get the exception

Error 500: No getter method for property: "inrofol" of bean: "com.test.forms.CompForm"

Any hints ? Thanks

A: 

The No getter method for property: "inrofol" of bean: "com.test.forms.CompForm" message is coming from the org.apache.struts.taglib.TagUtils. There is no other class throwing that kind of message.

But since TagUtils just provides helper methods for Struts JSP tags, it means some Struts tag is using your "inrofol" field somewhere and trying to look for it in your bean.

Are you sure that "inrofol" is used only on this piece of code from your JSP?

<input name="inrofol" class="inputfilter" id="inrofol" size="22" maxlength="20" type="text">

Check your valComp.jsp file.

dpb
All the references to inrofol are in this line<input name="inrofol" type="text" class="inputfilter" id="inrofol" size="22" maxlength="20"> <!--<html:text property="inrofol" />-->Maybe the html-commented part is the problem
xain
The <!-- HTML comment --> comment works on the client side not the server side. That means this is being evaluated: <html:text property="inrofol" /> and from here your problem. Remove the comment all together or change it to server side comment which is <%-- JSP comment --%>
dpb
That was it .. thanks
xain
A: 

Please check you have the getters and setters correctly set.

Also have the form tag in strut's style as

<html:form>.

karthikn_jay