I am trying to populate an select box on JSP using the ActionForm class. In my action I am populating the action form as follows :
Action Class ------------------- // get all Info ArrayList aList = (ArrayList) accountMgr.getAllProductInfo(); Iterator itr = aList.iterator(); while (itr.hasNext()) { ProductDTO aDTO = (ProductDTO) itr.next(); oForm.addGroupList(aDTO.getCarName(), ""+ aDTO.getSequenceId()); aDTO = null; } jsp code ------------ <html:select property="myList"> <html:optionsCollection property="myList" label="columnName" value="columnCd"/> </html:select> My ActionForm code is as below : ------------------------------------------------- public class ABCForm extends ActionForm { private ArrayList myList = new ArrayList(); // inner bean for representing column beans public class ColumnBean { private String columnName; private String columnCd; public ColumnBean(String sColName, String sColCd) { columnName = sColName; columnCd = sColCd; } public String getColumnName() { return columnName; } public String getColumnCd() { return columnCd; } } public List getMyList() { return myList; } public void addMyList(String sColumnName, String sColumnCd) { myList.add(new ColumnBean(sColumnName, sColumnCd)); } } If I do a size in my action class before forwarding, I get the correct value. But for some reasons, the select box is not getting populated with the values. oForm.getMyList.size() // in Action Class where oForm is my ActionForm. I had done this previously and had it working. Not sure why I am unable to do it now. Any advise appreciated. Thanks. VFP. __________________________________ Do you Yahoo!? Meet the all-new My Yahoo! - Try it today! http://my.yahoo.com --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]