The moose likes Struts and the fly likes logic:iterate Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login

Win a copy of Android Security Essentials Live Lessons this week in the Android forum!
JavaRanch » Java Forums » Frameworks » Struts
Bookmark "logic:iterate" Watch "logic:iterate" New topic


Ranch Hand

Joined: May 29, 2002
Posts: 198
Hi ,
I have the below code snippet which displays list of time values.
I need to show distinctively the max and min time values e.g in some diff color from the rest. I have those two variables say max and min set in the form.I would like to know that while iterating how can I identify the max and min values so that I can format those distinctively.
the angular brackets have been removed in the below code.
<logic:iterate id="allTime" property="allTimeList" name="performanceForm">
<TD bean:write name="allTime"/></ TD>
Nimchi Yung
Ranch Hand

Joined: Jan 27, 2004
Posts: 71
Assuming you have scripting variables like minData, maxData.
You could try something like this:

Ranch Hand

Joined: May 29, 2002
Posts: 198
It is sorta covered in the JavaRanch Style Guide.
subject: logic:iterate
Similar Threads
Adding 1 row to specific section of a struts table using iterate tag
Using checkbox/multibox to delete items from a list
how to do a pagination like "Page: 1 2 3 4 5 6 7" in a jsp ?
logic iterate to display data on multiple columns
how to do a Pagination like "Page:1 2 3 4 5 6 " in a jsp?