• Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

logic iterate

 
amuthan
Greenhorn
Posts: 2
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
hello,
I have generated the listbox using logic:iterate, the vector contains somthing like this
v.add["a"]
v.add["b"]
when my jsp is loaded the listbox is also loaded, but I want to know how to set the value with "a" and "b" accordingly.
right now when my jsp is like this
<option value=" ">a</option>
<option value=" ">b</option>
This is being generated by the logic:iterate tag.
Thanks!
 
poornima balagopal
Ranch Hand
Posts: 83
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,
I never tried with list box. But with combobox instead of using logic:iterate you can populate the combobox.
Like
<bean efine name="borrowerType" id="borrowerTypeList" scope="request"/>
<html:select property="borrowerType" onchange="JavaScript:getBorrowerCodes()" tabindex="1">
<html ptions collection="borrowerTypeList" labelProperty="borrowerType"
property="borrowerType"/>
</html:select>
I dont know whether this will work for you
Try this way
 
Kiran Kumar
Ranch Hand
Posts: 107
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi
Check out this link
http://forum.exadel.com/viewtopic.php?t=120
there are example applications which u can check out for ur specific requirement.
there is one struts-exercise-taglib.war which i think will answer ur queries.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic