> In the JSP have comboboxes. > > PrepareFacilityAction > > ..... > .... > request.setAttribute("List1", getList1(form)); > ........... > ........... > > The Jsp the combox is filled > ........... > .......... > <html:select name="FacilityForm" property="selected"> > <html:options collection="List1" > property="value" labelProperty="label"/> > </html:select> > > .............. > ................ > > > > The JSP displayes fine with all the values in it. This JSP has required > fields in it. Used validator.xml to define al lthe required fields. > > There is a Save Button which is the submit button in the JSP. When clicked > on Save want the validations to be done and be in the same JSP. > > When Clicked on Save, it is not going into the DispatchFacilityAction > > But getting the error in JSP > Cannot find bean under name List1 ------ This List1 was in the request when > the JSP originally displayed. > > Why is this?
Maybe because Struts tries to set current selection in the List1 object, which has request scope and is already gone. Not sure about it though, I need to look into how Struts sets selected item for list-type property. > How to fix this. I would not create any objects outside ActionForm like you did with List1. Instead, I would define all objects that are needed to be displayed/updated as properties of ActionForm. This approach will keep all page-related objects in one place, and they all will be available at once. Michael. --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]