I'm implementing DynaActionform for the first time. I'm defining them in struts-config.xml.
<form-bean
name="loginForm"
dynamic="true"
type="org.apache.struts.validator.DynaValidatorForm">
<form-property name="userName" type="java.lang.String"/>
<form-property name="password" type="java.lang.String"/>
</form-bean>


<action
   path="/signin"
   type="com.acme.LoginAction"
   scope="request"
   name="loginForm"
   validate="true"
   input="/start/signin.jsp">
   <forward name="Success" path="/action/mainPage.jsp"/>
   <forward name="Failure" path="/start/signin.jsp" redirect="true"/>
 </action>

The problem seems to be when I try to reference the form in the Action class's execute method. I get an error message in LoginAction "Unresolved symbol LoginForm".

public ActionForward execute(){
        String userName = ((LoginForm)form).getUserName();
        String password = ((LoginForm)form).getPassword();
}

Anyone have an idea where I went wrong?

Richard


--------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]



Reply via email to