> How can I populate dropdown list from form bean? What is the > structure of getter and setter methods required? > > Actually the values of drop down list are coming from database > which gets populated into the form bean now from form bean > how can that be populated in dropdown list?
Try this. In your Action: ArrayList months = new ArrayList(); months.add(new LabelValueBean("January", 1); months.add(new LabelValueBean("Februrary", 2); request.setAttribute("months", months); Inside your JSP: <html:form action="/yourActionMapping"> <html:select property="yourFormProperty" multiple="true"> <html:options collection="months" property="value" labelProperty="label" /> </html:select> </html:form> > Also how can the reverse of this, that is once I select multiple selections from > this list are set into the form bean? Make your Form attribute a String[]. -= J --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]