Hmm, never had a problem like this with a TileList. You can try myOldArrayCollection.removeAll(), before setting to the new ArrayCollection. (Hack) Also, make sure that you reset any filterFunctions that you may be using. Perhaps there is something else that is not getting reset before you try to add; some kind of cache? Or, the problem is with the add logic. If the TileList clears, then the dataProvider is clear (filterFunction withstanding). I would look around a little wider, in addition to fucusing on the TileList.
-TH --- In [email protected], "Ritu Raj Tiwari" <rituraj.tiw...@...> wrote: > > Jake, > Thanks for your response, but this did not help. I am still seeing the exact same behaviour. It is as if changing the data provider somehow does not really clean things out in the tile list. > > -Raj > --- In [email protected], "jake@" jake@ wrote: > > > > Instead of switching arraycollections, leave the arraycollection alone and alter the arraycollection.source (Array). I've had weird things happen with binding to an arraycollection and just altering the source array fixed the issue. > > > > -- > > Jake Churchill > > CF Webtools > > 11204 Davenport, Ste. 100 > > Omaha, NE 68154 > > http://www.cfwebtools.com > > 402-408-3733 x103 > > > > ---------------------------------------- > > From: "Ritu Raj Tiwari" rituraj.tiwari@ > > Sent: Tuesday, May 05, 2009 8:31 PM > > To: [email protected] > > Subject: [flexcoders] TileList dataprovider change bug? > > > > I am seeing some strange behaviour with TileList. I am hoping someone can shed some light on this: > > > > I have a TileList where I assign it an ArrayCollection for its dataProvider. As I add objects to this collection, the tile list updates faithfully. > > > > The problem happens when I switch the dataProvider to a new one. I start with an empty array collection and sure enough, the tile list is empty. When I add the first item to the new dataProvider, I see the last item from the previous dataProvider as the first entry in the list. As I add more items, I see more items from the previous data provider. > > > > Has someone else encountered this? It is definitely a bug, I am wondering if there is an easy workaround, like, say, creating my own TileList subclass that clears the right thing? > > > > Thanks in advance for any insights. > > > > -Raj > > >

