submit 2 ActionForms from one form

  • Oleg

    Oleg - 2005-11-23

    I am trying to get 2 actions execute one after another. Each action will have its own actionform. And all values for both forms will be posted from one JSP file containing one form. I asked this question on Struts mailing list and have been told its possible to do with Dialogs but I havent gotten far, playing with it. Could any one shed some light on this? Thank you much.

    • Michael Jouravlev

      The above setup is not directly possible with dialogs, because after input phase is concluded, DialogAction redirects to the view, thus losing request information.

      You may try either to redirect from one action to another, sticking data from first request into URL of second request manually.

      Or you may try to forward from one action to another, but I am not sure, will Struts populate second formbean, and will request object still contain data from first request.


    • Oleg

      Oleg - 2005-11-24

      Hi Michael,

      Thanks for the response. Is this your article :)

      I will try out Two actions, two forms. section there.

      Thanks again

    • Michael Jouravlev

      Yes, that is my article. I was doing some testing with multiple actions myself that time. I hope the setup described in the article works :-)


Log in to post a comment.