| Author |
Passing MyForm parameters with database retrieved values to Multiple Struts Actions
|
sriram arul
Greenhorn
Joined: Dec 10, 2012
Posts: 2
|
|
Hi,
I have a viewaction that gets data from db and i have edit button on the view page, now clicking on that it should take the user to the edit page ; here i dont want to hit the db again to get the details rather i would prefer passing the action form to the edit action so that i get the values there. from edit page i would be setting new values and that should be taken to the confirm action. the problem here is i am using the same form for all the actions and i am getting null values while the form is submitted.
how to proceed further ?
note: we are using struts 1.3.
|
 |
jatan bhavsar
Ranch Hand
Joined: Jul 23, 2008
Posts: 296
|
|
Hi Ram,
Set the the value in the form object while you fetch the data from the db and use it in action for edit page.
Regards
Jatan
|
 |
sriram arul
Greenhorn
Joined: Dec 10, 2012
Posts: 2
|
|
Hi Jatan,
Thanks for your efforts.
I have set my scope="session" in struts-config, and fetched data on next action page using form object. And finally it worked as expected.
Regards,
Ram
jatan bhavsar wrote:Hi Ram,
Set the the value in the form object while you fetch the data from the db and use it in action for edit page.
Regards
Jatan
|
 |
 |
|
|
subject: Passing MyForm parameters with database retrieved values to Multiple Struts Actions
|
|
|