This content has been marked as final. Show 3 replies
Have you tried saving 'openNodes' and then reassigning it after the refresh?
Yes, I try saving the nodes like this:
//save the currently opened items
openArray = new Array();
for each(var obj:Object in advancedDataGrid.openItems)
openArray = openArray.concat(obj);
and then restoring them with the expand function:
//expands the nodes which are passed in as the argument
private var expand:Function = function(array:Array):void
for each(var obj:Object in array)
Unfortunately, expandItem just seems to return without doing anything!
There is already a bug logged that grouping collection is not updating when source flat collection is updated - https://bugs.adobe.com/jira/browse/FLEXDMV-920.
If the fields (which are not present in the grouping fields) are modified. the collection will update without closing the opened nodes.
If you modify the group fields, new groups are created and thus the new group is in a closed state.
There is no need to add an event listener to the flat collection and to refresh the grouping collection.