Hi,

I have a Jewel DataGrid where the user can change the data outside of the
DataGrid.
To proper refresh the DataGrid (without timmers or hacks like dataProvider
= null), I checked the ArrayList source and tested this simple method that
works perfectly:
dataProvider.dispatchEvent(new Event('collectionChanged'));

So I have created a method inside my DataGrid "refresh":

public function refresh():void
{
if (dataProvider != null)
dataProvider.dispatchEvent(new Event('collectionChanged'));
}

Of course that this works with Royale ArrayList and was not tested with mx
ArrayCollection but I guess that almost all of us use ArrayList for Jewel
and ArrayCollection for mx emulation.

Since this is a specific approach method (not the bead way) to solve
this problem I guess that this can't be added to the DataGrid.as Royale
source code.
Correct me if I'm wrong.

Regards,
Hugo.

Reply via email to