Java Mailing List Archive

http://www.junlu.com/

Home » Home (12/2007) » Tomcat Users »

Can't find method to write bean property

Adam Buglass

2004-05-06

Replies:

This has had me puzzled for a couple of days now.

I've checked the docs, the faqs and the list archives.

I have a JSP which attempts to save information to a bean usinglines of
code such as:

<jsp:setProperty name="thisUser" property="userid" />

The corresponding Java is:

private String userID;
public void setUserid( String LuserID )
{
//    this.userID = LuserID;
    userID = LuserID;
}

As you can see, I've attempted using both lines of code that are in the
method.

Everytime I see evidence of another similar problem it has been fixed by
using the value attribute in the JSP like:
<jsp:setProperty name="thisUser" property="userid" value="" />
but this hasn't worked for me.

I *always* get the following error:
org.apache.jasper.JasperException: Can't find a method to write property
'userid' in a bean of type 'ISPSelfCare.Login'

I've checked the obvious such as package / class names etc.

Has anyone got any ideas where I'm making the error?

Thanks
Adam.



---------------------------------------------------------------------
To unsubscribe, e-mail: tomcat-user-unsubscribe@(protected)
For additional commands, e-mail: tomcat-user-help@(protected)

©2008 junlu.com - Jax Systems, LLC, U.S.A.