File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
The moose likes Struts and the fly likes Error: Cannot retrieve mapping for action /Name Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Frameworks » Struts
Bookmark "Error: Cannot retrieve mapping for action /Name" Watch "Error: Cannot retrieve mapping for action /Name" New topic
Author

Error: Cannot retrieve mapping for action /Name

pradeep chellappan
Greenhorn

Joined: Oct 20, 2005
Posts: 26
Hi ,

I am getting the following error:

Error: Cannot retrieve mapping for action /Name



Code Snippet:
----------------

index.jsp

<html:form action="Name" name="nameForm" type="example.NameForm">

struts-config.xml

<form-beans>
<form-bean name="nameForm" type="example.NameForm"></form-bean>
</form-beans>

<action path="/Name"
type="example.NameAction"
name="nameForm"
input="/index.jsp"
>
<forward name="success" path="/displayname.jsp" />
<forward name="failure" path="/index.jsp"/>

</action>
Please let me know what mistake i have commited.
pradeep chellappan
Greenhorn

Joined: Oct 20, 2005
Posts: 26
Hi All,

I got the problem myself....

i missed out to include <action-mappings>tag in struts-config.xml.

Balu Sadhasivam
Ranch Hand

Joined: Jan 01, 2009
Posts: 874

Just a a minute late in asking you the complete struts file. Its always better to post your complete struts config file for these kind of errors.By the way did your server did not thrown an error with wrong config file configurations?
 
 
subject: Error: Cannot retrieve mapping for action /Name
 
Similar Threads
tomcat problem.
struts 2 actionforms
Struts Sample Login Program
Struts Error Help Needed
I need a help to solve this error