You can change acUsers to a getter/setter and do what you want in the setter. The default setter event is propertyChange, but you can change that to whatever you want.
-TH --- In [email protected], "lampei" <lam...@...> wrote: > > Anyone have any suggestions? Seems like something everyone uses at some point, so I figured someone would know... > > --- In [email protected], "lampei" lampei@ wrote: > > > > The problem: > > I currently have a model that has properties bound to my view (a datagrid populated from an arraycollection, call it myModel.acUsers). The arraycollection is populated from a remote object call. However, if I set listeners on that ArrayCollection, once the remote call returns the data, and I set it to the arraycollection, the original listener I had set on the arraycollection gets removed, correct? > > > > In diving into the ListCollectionView, I saw that when the source gets set, it fires the "listChanged" event, so I can do a myModel.acUsers.source = ( event.results as ArrayCollection ).source and the event fires, and my original listeners do not get removed. The "listChanged" event is different than the ListEvent.CHANGE event though. So 2 questions: > > 1) Is this the best way to do this (I always have trouble listening for events on arraycollections when returning the values from remote calls so I can perform an action once the data is returned) > > 2) Is there a specific event set up for "listChanged" (such as ListEvent.LIST_CHANGED) or do I just need to continue listening for it like myModel.acUsers.addEventListener( "listChanged", handleListChanged ) ? > > > > Thanks > > >

