Home | JSP | EJB | JDBC | Java Servlets | WAP  | Free JSP Hosting  | Spring Framework | Web Services | BioInformatics | Java Server Faces | Jboss 3.0 tutorial | Hibernate 3.0 | XML

Tutorial Categories: Ajax | Articles | JSP | Bioinformatics | Database | Free Books | Hibernate | J2EE | J2ME | Java | JavaScript | JDBC | JMS | Linux | MS Technology | PHP | RMI | Web-Services | Servlets | Struts | UML


 

Java Tutorials


 

 

Struts Tutorials

Struts Resources

Visit Forum! Post Questions!
Jobs At RoseIndia.net!

Struts Struts LookupDispatchAction

User Comments
Add This Tutorial To:
  Del.icio.us   Digg   Google   Spurl
  Blink   Furl   Simpy   Y! MyWeb 

Add This Tutorial To:
  Del.icio.us   Digg   Google   Spurl   Blink   Furl   Simpy   Y! MyWeb 

Current Comments

7 comments so far (post your own) View All Comments Latest 10 Comments:

I think that the links in the JSP page should look something like this ...

<html:link page="/LookupDispatchAction.do?parameter=roseindia.net.add">Call Add Section</html:link>

The parameter values hat to match with the names used in the method getKeyMethodMap of the LookupDispatchAction ...

This is the way struts find the method to call ...

Posted by eze72 on Saturday, 03.15.08 @ 13:49pm | #52812

<html:link page="/LookupDispatchAction.do?parameter=add">Call Add Section</html:link>

This does not display as a link in my browser at all.it is converted into plain text.

Posted by Anand Kiran on Thursday, 11.15.07 @ 17:04pm | #37494

Hi
in the above example they specified that no need to create Actionform Class, but it is not working when actionForm class is not created.

Posted by sujith on Tuesday, 11.13.07 @ 22:58pm | #37277

interested but a bit confused with mapping in the struts-cofig.xml.

would you please send me an explanation on that.

thanx

Posted by pontsho on Sunday, 10.7.07 @ 12:53pm | #32311

I have tried the same code as above. but i am getting the following exception. Can anybody help me????????????
javax.servlet.ServletException: Action[/LookupDispatchAction] missing resource 'add' in key method map
at org.apache.struts.actions.LookupDispatchAction.getLookupMapName(Ljavax.servlet.http.HttpServletRequest;Ljava.lang.String;Lorg.apache.struts.action.ActionMapping;)Ljava.lang.String;(LookupDispatchAction.java:240)
at org.apache.struts.actions.LookupDispatchAction.getMethodName(Lorg.apache.struts.action.ActionMapping;Lorg.apache.struts.action.ActionForm;Ljavax.servlet.http.HttpServletRequest;Ljavax.servlet.http.HttpServletResponse;Ljava.lang.String;)Ljava.lang.String;(LookupDispatchAction.java:281)
at org.apache.struts.actions.LookupDispatchAction.execute(Lorg.apache.struts.action.ActionMapping;Lorg.apache.struts.action.ActionForm;Ljavax.servlet.http.HttpServletRequest;Ljavax.servlet.http.HttpServletResponse;)Lorg.apache.struts.action.ActionForward;(LookupDispatchAction.java:158)
at org.apache.struts.action.RequestProcessor.processActionPerform(Ljavax.servlet.http.HttpServletRequest;Ljavax.servlet.http.HttpServletResponse;Lorg.apache.struts.action.Action;Lorg.apache.struts.action.ActionForm;Lorg.apache.struts.action.ActionMapping;)Lorg.apache.struts.action.ActionForward;(RequestProcessor.java:419)
at org.apache.struts.action.RequestProcessor.process(Ljavax.servlet.http.HttpServletRequest;Ljavax.servlet.http.HttpServletResponse;)V(RequestProcessor.java:224)
at org.apache.struts.action.ActionServlet.process(Ljavax.servlet.http.HttpServletRequest;Ljavax.servlet.http.HttpServletResponse;)V(ActionServlet.java:1192)
at org.apache.struts.action.ActionServlet.doGet(Ljavax.servlet.http.HttpServletRequest;Ljavax.servlet.http.HttpServletResponse;)V(ActionServlet.java:412)
at javax.servlet.http.HttpServlet.service(Ljavax.servlet.http.HttpServletRequest;Ljavax.servlet.http.HttpServletResponse;)V(HttpServlet.java:740)
at javax.servlet.http.HttpServlet.service(Ljavax.servlet.ServletRequest;Ljavax.servlet.ServletResponse;)V(HttpServlet.java:853)
at weblogic.servlet.internal.ServletStubImpl$ServletInvocationAction.run()Ljava.lang.Object;(ServletStubImpl.java:971)
at weblogic.servlet.internal.ServletStubImpl.invokeServlet(Ljavax.servlet.ServletRequest;Ljavax.servlet.ServletResponse;Lweblogic.servlet.internal.FilterChainImpl;)V(ServletStubImpl.java:402)
at weblogic.servlet.internal.ServletStubImpl.invokeServlet(Ljavax.servlet.ServletRequest;Ljavax.servlet.ServletResponse;)V(ServletStubImpl.java:305)
at weblogic.servlet.internal.WebAppServletContext$ServletInvocationAction.run()Ljava.lang.Object;(WebAppServletContext.java:6350)
at weblogic.security.acl.internal.AuthenticatedSubject.doAs(Lweblogic.security.subject.AbstractSubject;Ljava.security.PrivilegedAction;)Ljava.lang.Object;(AuthenticatedSubject.java:317)
at weblogic.security.service.SecurityManager.runAs(Lweblogic.security.acl.internal.AuthenticatedSubject;Lweblogic.security.acl.internal.AuthenticatedSubject;Ljava.security.PrivilegedAction;)Ljava.lang.Object;(SecurityManager.java:118)
at weblogic.servlet.internal.WebAppServletContext.invokeServlet(Lweblogic.servlet.internal.ServletRequestImpl;Lweblogic.servlet.internal.ServletResponseImpl;)V(WebAppServletContext.java:3635)
at weblogic.servlet.internal.ServletRequestImpl.execute(Lweblogic.kernel.ExecuteThread;)V(ServletRequestImpl.java:2585)
at weblogic.kernel.ExecuteThread.execute(Lweblogic.kernel.ExecuteRequest;)V(ExecuteThread.java:197)
at weblogic.kernel.ExecuteThread.run()V(ExecuteThread.java:170)
at java.lang.Thread.startThreadFromVM(Ljava.lang.Thread;)V(Unknown Source)

Posted by Venkatesh on Friday, 09.28.07 @ 08:57am | #30119

its very good exapmle, everyone understand easily

Posted by rajender on Wednesday, 09.19.07 @ 15:33pm | #27841

I have implemented the code EXACTLY as presented here.
When I click any of the Call Add/Edit/Search/Save Section links the app doesn't forward to the jsp page.

What may be the problem here?
I have been following this tutorial from the beginning and this is the first problem I have come up against.

Posted by Du on Friday, 05.25.07 @ 17:02pm | #17244

Ask programming questions?

 

 

Back to Tutorial

 

  JDO Tutorials
  EAI Articles
  Struts Tutorials
  Java Tutorials
  Java Certification

Tell A Friend
Your Friend Name

 

 
Browse all Java Tutorials
Java JSP Struts Servlets Hibernate XML
Ajax JDBC EJB MySQL JavaScript JSF
Maven2 Tutorial JEE5 Tutorial Java Threading Tutorial Photoshop Tutorials Linux Technology
Technology Revolutions Eclipse Spring Tutorial Bioinformatics Tutorials Tools SQL
 

Home | JSP | EJB | JDBC | Java Servlets | WAP  | Free JSP Hosting  | Search Engine | News Archive | Jboss 3.0 tutorial | Free Linux CD's | Forum | Blogs

About Us | Advertising On RoseIndia.net  | Site Map

India News

Send your comments, Suggestions or Queries regarding this site at roseindia_net@yahoo.com.

Copyright 2007. All rights reserved.