The problem is that DataGrid is bound to the ArrayList and in most cases this ArrayList is stored locally, so just calling invalidateList() on DataGrid is not enough. I had my DataGrid bound to a MySQL data table and that’s how I succeeded:
FlexGlobals.topLevelApplication.getRunningTestsResult.token = FlexGlobals.topLevelApplication.testService.getRunningTests();
//dataGrid.invalidateDisplayList();
dataGrid.invalidateList();
getRunningTestsResult() is my function in bounded service in PHP that downloads running tests. I had to “update” the array (i.e. fill it with data once more). Then I used invalidateList() that moved data from the Array to DataGrid.
You can you a [Bindable] Array to make changes “in real time”. So this is a half-solution.
Note:
I used FlexGlobals.topLevelApplication just because I updated DataGrid from ItemRunderer. If you do this locally there is no need to use global vars.
Very good post, I served a lot of help, Thanks!
ReplyDeleteThis really helped me, thanks.
ReplyDeleteNice information, valuable and excellent design, as share good stuff with good ideas and concepts, lots of great information and inspiration, both of which I need, thanks to offer such a helpful information here.
ReplyDeletepython internship | web development internship |internship for mechanical engineering students |mechanical engineering internships |java training in chennai |internship for 1st year engineering students |online internships for cse students |online internship for engineering students |internship for ece students |data science internships