5 Replies Latest reply on Jun 27, 2009 3:39 PM by cratica

    How to get the id from a list?

    cratica Level 1

      For the following list, how can I access the preceeding number of each member?  (the 2, the 3...)

       

      templist = [2: "blah blah blah, 3: "yada yada yada"]

       

       

      The list is the result of an xtra that returns joystick id's from Windows so that is something that is not controlled ( can't change the list).  Sometimes, it will be 1:.... , 2:....   sometimes it will be 3:...  4:....  etc....   Point is, the list will be random based on what Windows reports.

       

       

      I tried using "the delimiter = ","... doesn't work.

       

      put templist[1] always returns the same thing....

       

      "blah blah blah"

       

       

      What I need is to be able to determine what index is assocated with "blah blah blah"  (answer would be 2)

       

       

      Any thoughts?