Matt,
 
Doing a redirection causes a new request to be created, thus you loose
everything you put in the previous request object.  You could save your messages in user session scope, then do your redirection.  The next page will have access to the user session and you'll be able to read those messages.  After messages are read, you can remove the bean from session scope in order preserve memory on the server.
 
Andre Paradis
-----Original Message-----
From: Matt Raible [mailto:[EMAIL PROTECTED]]
Sent: Tuesday, August 28, 2001 2:01 PM
To: Struts User
Subject: Validation FW: Displaying messages passed the request

I have a SaveAction that sets up some success messages using:
 
messages.add(new ActionMessage("timesheetManage.save.success"));
saveMessages(Constants.MESSAGE_KEY, request, messages);
 
 
And upon this save, the findForward("success") forwards to another action class with:
 
<forward
          name="success"
          path="/do/editTimesheet?action=Edit" redirect="true" />
 
But on the JSP after, there are no messages displayed.  I know the answer why, and that is because "redirect=true".  However, this is the only way I can forward to another action class in iPlanet.
 
Anyone know of a workaround to carry these messages into the next page?  Can I check the request in "editTimesheet" to see if messages exist, and if so - add them to the request again?
 
Thanks,
 
Matt
 
 
 

Reply via email to