1 Reply Latest reply on Sep 1, 2008 6:43 AM by Ilya Shaikovsky

    iteration problem with dropDownMenu

    Eric Eisenhower Newbie

      Using 3.2.1GA, JSF 1.2

      I am trying to iterate through an array to build a dropDownMenu.

      Tried using a4j:repeat, and it doesn't repeat. Saw somewhere that perhaps that is not supposed to work. No errors though.

      Tried using c:forEach, and that does not work either. It just does not iterate. Again no errors.

      I can do both the a4j:repeat and c:forEach on the array outside of the dropDownMenu, and both work a treat, so I don't think it is a problem with my data.

      Here is a snippet:

      <rich:dropDownMenu value="Index...">
       <c:forEach items="#{ImageViewer.objectMenuItems}" var="oti" >
       <rich:menuItem value="#{oti.name}"/>
       </c:forEach>
      </rich:dropDownMenu>
      

      All I get is an empty menu.

      Thanks for any help!