I have a TileList in my application where each element is rendered by 
a custom ItemRenderer. Each element of the above TileList
has another TileList in it which is rendered for the first time by
initialize event.

The outer TileList's dataprovider is an ArrayList of VO's which are
returned from the server side. There is an inner array in each 
of the elements of the above ArrayList which requires some processing
to create another ArrayList which becomes the dataprovider for the 
inner TileList(s).

I have a button on my UI clicking on which I change the dataprovider 
of the outer TileList to a new ArrayList(containing exact same type of 
elements as before but with different data). I could not find an easy
way to re-render the inner TileList(s) based on the new dataprovider 
for the outer TileList. 

After searching the list, I found a reply from Matt on a similar
problem where he instructed to override the set data method for the
outer TileList & refresh the datprovider of inner TileList in the body
of the overridden method. This part works perfectly. 

But if I try to dispatch a FlexEvent.DATA_CHANGE from the overriden 
set data method & put a dataChange handler on the outer TileList, 
the datachange handler doesn't get called. Is this a bug or expected 
behavior ? How do I receive the notification for dataChange event ? 
I was thinking of switching the dataProvider of the inner TileList 
in dataChange handler. Is this not the right way ?

Thanks,
Aejaz

Reply via email to