You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@struts.apache.org by Marco Mistroni <mm...@waersystems.com> on 2003/12/23 12:25:30 UTC
Error in JSP when using DynaActionForm
Hi all,
I am trying to get things working with DynaActionform.
I have defined my dynaAction form in my struts-config file as follows..
<form-bean name="productAliasForm"
type="org.apache.struts.validator.DynaValidatorForm">
<form-property name="aliasRef" type="java.lang.String"/>
<form-property name="contactRef" type="java.lang.String"/>
<form-property name="productRef" type="java.lang.String"/>
</form-bean>
mapped to following class
<action path="/productContactAliasSetUp"
type="com.waersystems.ngenweb.product.ProductSetUpAction"
name="productAliasForm"
validate="false" scope="request">
<forward name="blank"
path="/productMaintenance.jsp">
</forward>
</action>
now, when the ProductSetupAction forward the request to
productMaintenance.jsp,
I got following JSP compilation error:
ServletException in:/AliasMaintenance.jsp] No getter method for property
aliasRef of bean org.apache.struts.taglib.html.BEAN'
At a glance, it seems that the page does not recognize the
DynaActionForm, since it is expecting to have a getAliasRef, while the
DynaActionForm has only get and set..
Any additional steps that I have to configure still in JSP to get things
working?
Thanx and regards
marco
---------------------------------------------------------------------
To unsubscribe, e-mail: struts-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: struts-user-help@jakarta.apache.org
Re: Error in JSP when using DynaActionForm
Posted by Mark Lowe <ma...@talk21.com>.
Its actually expecting
theForm.get("aliasRef");
and
theForm.set("aliasRef","foo");
but this shouldn't make any difference in the jsp as
getAliasRef() and get("aliasRef").. are the same thing in the jsp (well
in terms of the jsp one uses to access the properties.)
Cheers Mark
On 23 Dec 2003, at 11:25, Marco Mistroni wrote:
> Hi all,
> I am trying to get things working with DynaActionform.
> I have defined my dynaAction form in my struts-config file as follows..
>
> <form-bean name="productAliasForm"
> type="org.apache.struts.validator.DynaValidatorForm">
> <form-property name="aliasRef" type="java.lang.String"/>
> <form-property name="contactRef" type="java.lang.String"/>
> <form-property name="productRef" type="java.lang.String"/>
> </form-bean>
>
> mapped to following class
>
> <action path="/productContactAliasSetUp"
>
> type="com.waersystems.ngenweb.product.ProductSetUpAction"
> name="productAliasForm"
> validate="false" scope="request">
> <forward name="blank"
> path="/productMaintenance.jsp">
> </forward>
> </action>
>
>
> now, when the ProductSetupAction forward the request to
> productMaintenance.jsp,
> I got following JSP compilation error:
>
> ServletException in:/AliasMaintenance.jsp] No getter method for
> property
> aliasRef of bean org.apache.struts.taglib.html.BEAN'
>
>
> At a glance, it seems that the page does not recognize the
> DynaActionForm, since it is expecting to have a getAliasRef, while the
> DynaActionForm has only get and set..
>
> Any additional steps that I have to configure still in JSP to get
> things
> working?
>
> Thanx and regards
> marco
>
>
>
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: struts-user-unsubscribe@jakarta.apache.org
> For additional commands, e-mail: struts-user-help@jakarta.apache.org
>
---------------------------------------------------------------------
To unsubscribe, e-mail: struts-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: struts-user-help@jakarta.apache.org