jwright9
asked on
Problem mapping an Action to a namespace
I am trying to get an action in a Struts 2 app to work but I am coming up with this error in my console. Is there any known fix for this?
There is no Action mapped for namespace /jsp/myApp/screenscrape and action name runEarningsAlerts. - [unknown location]
There is no Action mapped for namespace /jsp/myApp/screenscrape and action name runEarningsAlerts. - [unknown location]
ASKER
ProgSysAdmin, Thanks for your response but I am using the struts 2 struts.xml format for my configuration.
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
ASKER
I tried your code but I got the same result. I know yours should work. So I'll accept yours.
<struts-config>
<form-beans>
<form-bean name="searchForm"
type="org.SearchForm"/>
</form-beans>
<action-mappings>
<action path="/Search"
name="searchForm"
type="org.SearchAction" >
<forward name="Status" path="/status.jsp"/>
<forward name="NotFound" path="/login.jsp"/>
</action>
</action-mappings>
</struts-config>
Where type="org.SearchAction" defines your action class