Junilu Lacar, thanks for your help.
i have changed my display name according to the JavaRanch Naming Policy.
However I still have problems with the code I mentioned in my first posting.
1. I tried to get the collection by using the name "banks" directly in the iterate tag, however the following error cropped up:
org.apache.jasper.JasperException: Cannot create iterator for this
collection
Before calling the JSP I am calling an action that prepares the collection in a request attribute named banks - in fact using <%= request.getAttribute("banks") %> - I cannot understand why "banks" is not working.
2. I have added a String[] in the ActionForm and used the multibox successfully using the following code:
<html:multibox property="selectedBankIds">
<bean:write name="bank" property="id"/>
</html:multibox>
your code:
<html:multibox property="selectedBankIds" value="<%= bank.getId() %>" />
Maybe this problem is related to the fact that "banks" is not working in 1.
3.my last question is related to integrating
struts tags with javascript:
<html:submit value="Edit" on*="return callEdit('<%= ((com.fase.ims.logic.admin.Bank)bank).getId() %>')"/>
* in this case click
I am trying to pass the bank id to a javascript method. However this is not working - the scriplet is not being compiled and interpreted.
NOTE: I am using this messy approach since in my JSP I am generating a number of buttons dynamically, with each button's Action requiring the id (the bank id) corresponding to the clicked button. This was the only way I could think of going aroung this problem. Does anyone has a better solution?
thanks for all your help,
colin pace