Thanks for your post Raghu,

 

I changed the code but then I received the following exception:

 

org.apache.struts.chain.commands.InvalidPathException: No action config
found for the specified url.

 
org.apache.struts.chain.commands.AbstractSelectAction.execute(AbstractSelect
Action.java:71)

 
org.apache.struts.chain.commands.ActionCommandBase.execute(ActionCommandBase
.java:51)

        org.apache.commons.chain.impl.ChainBase.execute(ChainBase.java:190)

 
org.apache.commons.chain.generic.LookupCommand.execute(LookupCommand.java:30
4)

        org.apache.commons.chain.impl.ChainBase.execute(ChainBase.java:190)

 
org.apache.struts.chain.ComposableRequestProcessor.process(ComposableRequest
Processor.java:283)

 
org.apache.struts.action.ActionServlet.process(ActionServlet.java:1913)

        org.apache.struts.action.ActionServlet.doGet(ActionServlet.java:449)

        javax.servlet.http.HttpServlet.service(HttpServlet.java:690)

        javax.servlet.http.HttpServlet.service(HttpServlet.java:803)

 

The thing is MenuAction handles the Menu, that's why it initialize
MessageList when some choose Message History menu.

 

Here's a extract: 

 

public ActionForward execute(ActionMapping actionMapping,

                                 ActionForm actionForm,

                                 HttpServletRequest servletRequest,

                                 HttpServletResponse servletResponse) throws

            Exception {

        int menuOption = (Integer)
PropertyUtils.getSimpleProperty(actionForm,

                "menuOption");

        

        String forward = "";

            UserTO user;

            try {

                  switch (menuOption) {

                  case MenuConstants.HOME:

                        forward = "home";

                  break;

            case MenuConstants.MESSAGES_HISTORY:

                  user = 

                        (UserTO)
servletRequest.getSession().getAttribute("user");

                        MessageListTO messages = new
MessageDAO().getMessages(user.getClientId());

                  servletRequest.getSession().setAttribute("messageList",
messages.getMessageList());

                  DateTO dateRange = new DateTO(2008);

                  servletRequest.getSession().setAttribute("dateRange", 

                             dateRange);

                  DateUtil dateTo = new DateUtil();

                  dateTo.setDay(dateTo.getCurrentDay());

                  dateTo.setMonth(dateTo.getCurrentMonth());

                  dateTo.setYear(dateTo.getCurrentYear());


                  servletRequest.setAttribute("dateTo",dateTo);

                        forward = "messages";

                        break;

            case MenuConstants.SEND_MESSAGE:

                        forward = "sendMessage";

                        break;                       

            default:

                        forward = "home";

                        break;

                  }

            } .

 

 

 

De: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] En nombre de
Raghuveer Kumarakrishnan
Enviado el: Wednesday, April 09, 2008 4:26 PM
Para: displaytag-user@lists.sourceforge.net
Asunto: Re: [displaytag-user] paging displaytag and struts

 

Francisco,

 

Set requestURI="MenuAction.do" 

 

--Raghu

Francisco Egloff Weil <[EMAIL PROTECTED]> wrote:

Hi, everyone 

I have problems linking displaytag with action/form/struts-config.xlm. 

This is what I have: 
MenuAction
- initialize the arraylist "messageList" 
- servletRequest.getSession().setAttribute("messageList",
messages.getMessageList()); 
- forwards = "Message.jsp" 

Message.jsp

pagesize="16" cellspacing="0"> 








When I click next on paging-menu I've got 
java.lang.NullPointerException 
at org.apache.jsp.WEBSITE.Messages_jsp._jspService 

I read on other post to set displaytags' attribute requestURI="" but it
doesn't work either. I know I have to configure something on
struts-config.xlm and create an action class associated with this. 

I'll appreciate any help you can give me on this. 

Best regards, 

Francisco 

PD. I'm using Tomcat as application server




-------------------------------------------------------------------------
This SF.net email is sponsored by the 2008 JavaOne(SM) Conference 
Don't miss this year's exciting event. There's still time to save $100. 
Use priority code J8TL2D2. 
http://ad.doubleclick.net/clk;198757673;13503038;p?http://java.sun.com/javao
ne
_______________________________________________
displaytag-user mailing list
displaytag-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/displaytag-user




A Goal .......... Is a Dream with a Deadline

 __________________________________________________
Do You Yahoo!?
Tired of spam? Yahoo! Mail has the best spam protection around 
http://mail.yahoo.com 

-------------------------------------------------------------------------
This SF.net email is sponsored by the 2008 JavaOne(SM) Conference 
Don't miss this year's exciting event. There's still time to save $100. 
Use priority code J8TL2D2. 
http://ad.doubleclick.net/clk;198757673;13503038;p?http://java.sun.com/javaone
_______________________________________________
displaytag-user mailing list
displaytag-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/displaytag-user

Reply via email to