Granny's Programming Pearls
"inside of every large program is a small program struggling to get out"
JavaRanch.com/granny.jsp
Win a copy of Think Java: How to Think Like a Computer Scientist this week in the Java in General forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

LookupDispatchAction: missing resource in key method map

 
Henry Lowell
Ranch Hand
Posts: 63
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I can't seem to figure out what the problem is. Now, before when I had the class just extend Action, everything worked. But now that I need LookupDispatchAction, I am getting this error:


javax.servlet.ServletException: Action[/AddUser] missing resource in key method map
org.apache.struts.actions.LookupDispatchAction.getLookupMapName(LookupDispatchAction.java:230)
org.apache.struts.actions.LookupDispatchAction.getMethodName(LookupDispatchAction.java:271)
org.apache.struts.actions.DispatchAction.execute(DispatchAction.java:173)
org.apache.struts.actions.LookupDispatchAction.execute(LookupDispatchAction.java:150)
org.apache.struts.action.RequestProcessor.processActionPerform(RequestProcessor.java:431)
org.apache.struts.action.RequestProcessor.process(RequestProcessor.java:236)
org.apache.struts.action.ActionServlet.process(ActionServlet.java:1196)
org.apache.struts.action.ActionServlet.doGet(ActionServlet.java:414)
javax.servlet.http.HttpServlet.service(HttpServlet.java:689)
javax.servlet.http.HttpServlet.service(HttpServlet.java:802)


The properties file for the resources are fine because other pages work just fine. Any help is apprecaited. I am sure it is something silly.

Resources:
adduser.button.save=Save
adduser.button.delete=Delete

fragment of AddUser extends LookupDispatchAction


fragment of JSP


fragment from struts-config
 
Zip Ped
Ranch Hand
Posts: 336
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Do you have methods named "save" and "delete" in your Action classes?
eg.


Also, have you defined the property "dispatch" in your ActionForm?(I dont think this would be the problem though)
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic