• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

how to loop through an array list of objects

 
Greenhorn
Posts: 15
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
an object X has an array list xyzList.

getXyzList() returns an array of objects Test

public Test[] getXyzList() {
}

The object Test() contains variables name and setting.

how do I loop through the xyzList to display values of name and setting

I tried the below ..seems like thats not the way to do. any help is appreciated.

Thank you ..

<s:iterator id="xyzLst" value="X.xyzList" status="alertSetting">

<tr>
<td><label>Setting Name:</label></td>
<td> <s:textfield value="%{#xyzLst[%{#alertSetting.index}]}"></s:textfield> </td>

</tr>
</s:iterator>
 
M Kethi
Greenhorn
Posts: 15
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Resolved !!
 
reply
    Bookmark Topic Watch Topic
  • New Topic