Please note that the SubmitAction is in the package
package hansen.playground;

thus the class should be :

--------------------Start--------------
package hansen.playground;

import javax.servlet.http.*;
import org.apache.struts.action.*;

public final class SubmitAction extends Action {

  public ActionForward perform(ActionMapping mapping,
      ActionForm form,
      HttpServletRequest request,
      HttpServletResponse response) {

    SubmitForm f = (SubmitForm) form; // get the form
bean
    // and take the last name value
    String lastName = f.getLastName(); 
    // Translate the name to upper case 
    //and save it in the request object 
    request.setAttribute("lastName",
lastName.toUpperCase());
    
    // Forward control to the specified success target
    return (mapping.findForward("success"));
  }
}
--------------------END--------------

--- Rajat Nayer <[EMAIL PROTECTED]> wrote:
> Hi All,
> 
> Greetings!!! I am the newest member on this list.
> 
> I am trying to setup the Struts (ver 1.0.1) using
> Tomcat 3.2.4 and following the tutorial at address:
> http://javaboutique.internet.com/tutorials/Struts/
> 
> I am facing the following issue:
> 
> On clicking submit on my JSP(submit.jsp), i am
> getting
> the foll error:
> 2003-06-10 14:55:07 - Ctx( /myproject ): 500 R(
> /myproject + /submit.do + null)
> No action instance for path /submit could be created
> 
> My struts-config.xml has the foll entries:
> ----START--------
> <struts-config>
> 
>   <!-- ========== Form Bean Definitions
> ================= -->
>   <form-beans>
> 
>     <form-bean      name="submitForm"
>                    
> type="hansen.playground.SubmitForm"/>
> 
>   </form-beans>
> 
>   <!-- ========== Action Mapping Definitions
> ============ -->
>   <action-mappings>
> 
>     <action   path="/submit"
>               type="hansen.playgound.SubmitAction"
>               name="submitForm"
>               input="/submit.jsp"
>               scope="request">
>     <forward name="success" path="/submit.jsp"/>    
>  
>    
>     <forward name="failure" path="/submit.jsp"/>    
>  
>    
>     </action>
> 
>   </action-mappings>
> 
> </struts-config>
> ---------END----------
> 
> 
> --------SubmitAction.java-------
> 
> 
> import javax.servlet.http.*;
> import org.apache.struts.action.*;
> 
> public final class SubmitAction extends Action {
> 
>   public ActionForward perform(ActionMapping
> mapping,
>       ActionForm form,
>       HttpServletRequest request,
>       HttpServletResponse response) {
> 
>     SubmitForm f = (SubmitForm) form; // get the
> form
> bean
>     // and take the last name value
>     String lastName = f.getLastName(); 
>     // Translate the name to upper case 
>     //and save it in the request object 
>     request.setAttribute("lastName",
> lastName.toUpperCase());
>     
>     // Forward control to the specified success
> target
>     return (mapping.findForward("success"));
>   }
> }
> --------------END--------------
> 
> Please help me move ahead...
> 
> Please let me know in case more files are reqd for
> reference.
> 
> Thanks
> Rajat
> 
> 
> 
> 
> 
> 
> __________________________________
> Do you Yahoo!?
> Yahoo! Calendar - Free online calendar with sync to
> Outlook(TM).
> http://calendar.yahoo.com
> 
>
---------------------------------------------------------------------
> To unsubscribe, e-mail:
> [EMAIL PROTECTED]
> For additional commands, e-mail:
> [EMAIL PROTECTED]
> 


__________________________________
Do you Yahoo!?
Yahoo! Calendar - Free online calendar with sync to Outlook(TM).
http://calendar.yahoo.com

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

Reply via email to