5 Replies Latest reply on May 17, 2010 3:01 PM by UbuntuPenguin

    Bind Dictionary to dataProvider

    anoweb
      I have a class which stores data in a dictionary such as:

      [Bindable]
      public var data:Dictionary;

      Person bill = new Person("bill");
      data["bill"] = bill;

      Ok, I have a DataGrid which I would like to bind to this dictionary's values (i.e. the Person objects). I realize that the "dataProvider" for a DataGrid can only be an ArrayCollection so is there a nice way to get the dictionary values into an ArrayCollection?

      Or do I have to maintain a separate ArrayCollection just to let the view bind to it?