2 Replies Latest reply on Jul 13, 2009 10:32 AM by yial2

    Nested Repeater Problem

    chris00chris Level 1
      Hi All,

      I have a nested Repeater structure (please see attached code). There is an outer Repeater which contains a VBox with another inner Repeater inside that. I add items one at a time to the Repeaters to create a tree like structure that should look like:

      Outer0
      Inner0
      Inner1
      Outer1
      Inner0
      Inner1

      If the outer Repeater is set with recycleChildren="true" then the inner Repeater data is shown incorrectly, specifically it looks like:

      Outer0
      Inner0
      Inner0 (Should be Inner1)
      Outer1
      Inner0
      Inner1

      If the VBox between the outer and inner Repeaters is removed then the Repeaters work correctly.

      I believe there is a problem here in that when a Repeater recycles it's components it checks to see if each component is also a [nested] Repeater and if so it executes that Repeater. However, if the nested/inner Repeater is not a direct descendent of the outer Repeater (ie. in this example there is a VBox between the inner and outer Repeaters) then any [grand]child Repeaters are not executed.

      Has anyone else come across this? Am I doing something wrong and/or is there a workaround? I may be able to fix it if I can force the Repeater to execute, but unfortunately the execute method is private.

      Incidentally, I do not want to set recycleChildren to false as this causes a flicker, and I need the VBox inbetween for layout purposes.

      Thanks a lot,
      Chris.


      ----