Bill - The point of my discussion was the following premise:
public class MyCheckboxForm extends ActionForm public class MyForm1 extends MyCheckboxForm public class MyForm2 extends MyCheckboxForm I want to be able to pass MyForm1 or MyForm2 to the same JSP and have it work because the JSP is only concerned with the contents within MyCheckboxForm, but I dont think I can do this, at least not cleanly. So what I have considered is the following alternative: public class MyForm1 extends ActionForm public class MyForm2 extends ActionForm public class MyCheckboxForm extends ActionForm Then, when MyForm1 is posted to my action, it will instantiate a MyCheckboxForm object in the request scope, transfer the MyForm1 object from request to session scope for later retreival and note the bean name in the MyCheckboxForm. Populate the needed data from MyForm1 into MyCheckboxForm and finally forward to this common JSP. This JSP will do its thing and finally posts its data back to an action with a flag that says, "we're done, transfer data back". The MyCheckboxForm contains the bean-name of MyForm1 which was in the session scope, the action retreives it, transfers the data from the MyCheckboxForm back into MyForm1, updating it accordingly and then removes the session-scope MyForm1 and puts it back into the request scope forwarding the user to the final JSP which renders the changes made by the checkbox logic. The point is we want to have a single form which we can manipulate label/value(s) via checkbox selection and pagination. Once the user have selected "save/return", the data of all their selections gets passed back to the original form which will later be used for a search query. Like I said, I think what I decided on as an alternative seems to be a much cleaner and easier approach as it removes any "ties" between the forms themselves and really lets the "core logic" of the checkbox form stand alone for usability for any other future purpose. Thanks in advance! Chris ----- Original Message ----- From: "Bill Siggelkow" <[EMAIL PROTECTED]> To: <[EMAIL PROTECTED]> Sent: Saturday, June 19, 2004 3:22 PM Subject: Re: bean defines > Chris, your running into the problem because when you use <bean:define> > where the value is specified in the body of that tag, it create a new > String scripting variable as well as a page-scoped attribute that is > also a String. > > Instead, you want the actual form bean itself. I am not too sure about > how tiles fits into the mix but for a normal action mapping where the > form was specified as "MyForm" in the name attribute you could simply do > the following: > > The Page Number: <c:out value="${MyForm.pageNumber}" /> --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]