2 Replies Latest reply on Jul 18, 2007 12:42 AM by Kgnytia

    Databinding Not Updating

      I am using a TileList with a custom ItemRenderer. I have assigned it's DataProvider to an ArrayCollection. The problem I am having is that when I update the ArrayCollection, the TileList does not update to show the changes.

      When debugging, I can look at the TileList.DataProvider, and it has the updates, but they do not display. Does anyone know what could cause this? My understanding was that using an ArrayCollection instead of an Array should make the changes appear automatically.

      The only way I found to fix this is to construct an entirely new ArrayCollection and assign it as the DataProvider.
        • 1. Re: Databinding Not Updating
          ntsiii Level 3
          How are you updating the ArrayCollection?

          Take out the renderer, put in a label, and see if the changes get shown. That will tell you if the issue is with the binding or with the renderer.

          • 2. Re: Databinding Not Updating
            Have your tried with refresh() ?

            var result : ArrayCollection = ArrayCollection((event as ResultEvent).result);
            myModel.myDataProvider = result;

            where myModel is [Bindable] on the mxml view and myModel.myDataProvider is the dataprovider of your TileList.

            good luck!