By default a '.do' is appended to the action mapping path specified in
struts-config.xml(don't know why or how to change this).

Try <html:form action="/searchCustomers.do">

> -----Original Message-----
> From: Swaminathan Gurumoorthy [mailto:[EMAIL PROTECTED]
> Sent: 11 June 2003 17:51
> To: [EMAIL PROTECTED]
> Subject: Problem with retrieving mapping
> 
> 
> Hi
>  
> I am a newbie to struts and I ran into problems with my very 
> first struts functionality.
> 
>  My customer lookup jsp has a lookup form and an iframe to 
> show the results. I am using a dynaform to harvest the 
> searchform entries.
>  
> In my customerSearch.jsp, I use a <html:form> to submit the 
> form like this
>  
> 
> <html:form method="post" action="/searchCustomers" 
> focus="custLookupNumber" target="searchresults" onsubmit 
> ="return false;">
> 
>  
> 
> My struts-config file has these entries
> 
>     <!-- ========== Form Bean Definitions 
> ================================== -->
>     <form-beans type="org.apache.struts.action.ActionFormBean">
>     
>      
>      <!-- Customer Lookup Form -->
>      <form-bean name="CustomerLookUpDF" 
> type="org.apache.struts.action.DynaActionForm">
>    <form-property name="custLookupNumber"  
> type="java.lang.String" initial=""/>
>    <form-property name="custLookupName"  
> type="java.lang.String" initial=""/>
>    <form-property name="custLookupAddress" 
> type="java.lang.String" initial=""/>
>    <form-property name="custLookupCity"  
> type="java.lang.String" initial=""/>
>    <form-property name="custLookupState"  
> type="java.lang.String" initial=""/> 
>    <form-property name="custLookupZip"     
> type="java.lang.String" initial="" />
>      </form-bean>
>        
>     </form-beans>
> 
>  
> 
>     <!-- ========== Action Mapping Definitions 
> =============================== -->
>     <action-mappings type="org.apache.struts.action.ActionMapping">
> 
> 
>         <!-- ======================= Customer LookUp 
> ======================== -->
>         <action
>             input="/callcenter/form/body/customerSearchBody.jsp" 
>             attribute="CUSTOMERLOOKUP" 
>             name="CustomerLookUpDF"
>             path="/searchCustomers"
>             type="com.mycompany.myapp.action.CustomerLookUpAction">
>             <forward name="Success" 
> path="/form/body/customerSearchResults.jsp" />            
>         </action> 
>   </action-mappings>
>  
> My action class uses a business delegate to query the 
> database with the dyna form 
> values and returns the collection to the 
> customerSearchResults.jsp. This will iterate thru 
> the collection to display the details.
>  
> I thought that was straight forward. But I get this error 
> when I call the customer lookup jsp.
>  
> The error is 
> 
> org.apache.jasper.JasperException: Cannot retrieve mapping 
> for action /searchCustomers
> at 
> org.apache.jasper.servlet.JspServletWrapper.service(JspServlet
> Wrapper.java:248)
> at 
> org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet
> .java:289)
> ......(stack trace continues)
>  
>  
> 
> root cause 
> javax.servlet.ServletException: Cannot retrieve mapping for 
> action /searchCustomers
> 
> at 
> org.apache.jasper.runtime.PageContextImpl.handlePageException(
PageContextImpl.java:494)
> 
> at 
> org.apache.jsp.customerSearchBody_jsp._jspService(customerSear
> chBody_jsp.java:84)...(stack trace continues)
> 
> What am I doing wrong? I checked for typos in 
> struts-config.xml against my jsps,action class et al.
> 
> 
> 
> Thanks in advance. 
> 
> 
> 
> 
> ---------------------------------
> Do you Yahoo!?
> Free online calendar with sync to Outlook(TM).
> 

DISCLAIMER: This message contains confidential information and is intended
for To: and Cc: (name). If you are not the intended recipient you are
notified that disclosing, copying, distributing or taking any action in
reliance on the contents of this information is strictly prohibited. E-mail
transmission cannot be guaranteed to be secure or error-free as information
could be intercepted, corrupted, lost, destroyed, arrive late or incomplete,
or contain viruses. The sender therefore does not accept liability for any
errors or omissions in the contents of this message, which arise as a result
of e-mail transmission. The content of this e-mail does not necessarily
represent the company, its policies, or views, or those of its subsidiaries.
If verification is required please request a hard-copy version.
Please note that M2 Limited monitors incoming and outgoing mail for
compliance with its email policy. This includes scanning incoming emails to
detect Viruses. 

Reply via email to