7 Replies Latest reply on Jan 28, 2009 9:30 AM by Gregory Lafrance

    Creating lists and collections on the fly?

    Handycam Level 1
      I have a XML data set that has a series of step (see code sample). Right now, I need to manually allow for the numer of "step" nodes in my data handler and "choice" nodes to assign to list collections for the app to use.

      My question is, how can I create a loop to look at the number of children and automatically create a listCollection and assign the data to it?

      Such as l0.dataProvider = new XMLListCollection(dp.step[0].choices.choice), where the zero would increment based on the number of nodes in the document?