1 Reply Latest reply on Jul 25, 2007 2:04 PM by ntsiii

    Apply selections from one array to another?

    Handycam Level 1
      I've got a List box. It's dataProvider is an Array, myArray1. The user makes selections (it's set for multi). I can get these via selectedItems or selectedindices. No problem. Let's say I store the selectedIndices in another array, "mySelections".

      No where's where I'm hung up: I have another array (myArray2). I need to select the items in this array that have the same indices as mySelections.

      For example, if the myArray = ["headgear", "outerwear", "footwear", "trousers", "shirts"]

      and the user selects 0,2,3

      And myArray2 = [ "cap", "parka", "boots", "jeans", "tanktop"]

      I want another array or string that includes 0,2,3 of myArray2, or "cap, boots, jeans"

      How would I do this? Thanks.