You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@struts.apache.org by Kalpana RamiReddy <ka...@rediffmail.com> on 2002/02/06 20:55:21 UTC
SAVE and GO
I have a question here.
I have 2 buttons in my page. one is "SAVE&GO" and the other is "SAVE".
when i click on "SAVE&GO" , it saves the data and goes to another page. And "SAVE" remains in the same page.
Now, I have a jsp page named "disposition.jsp"
This page contains the above buttons and a ScreenNumber textbox and a couple of other fields.
i fill the fields and give a ScreenNumber as 10 and press on "SAVE&GO",
it should first save the data and it should navigate to the 10th screen.
I have
1>disposition form bean (contains some fields to save)
2>disposition action form
3>navigation form bean (contains the screenNumber and its geter setter)
4>navigation action form ( Handles the navigation.If an invalid screen number or an invalid casenumber are provided, the user will be
forwarded to a default error page. )
5>disposition.jsp page
in struts-config.xml i have
<action path = "/phmuni/cms/disposition"
type = "com.verilaw.app.phmuni.cms.actions.CMSDispositionAction"
name = "dispositionForm"
scope = "request"
input = "/phmuni/cms/disposition.jsp">
<forward name="success" path="/phmuni/cms/disposition.jsp"/>
</action>
The thing is i can save the data when i press "SAVE" button. But now my question is when i press "SAVE&GO" how do i save the data and navigate to another screen based on ScreenNumber.
How should i get the ScreenNumber. Where should i set the Attribute.
some thing like
request.setAttribute("screenNumber",screenNumber)
how do i proceed????
--
To unsubscribe, e-mail: <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>