For this to work, the CollectionEventKind.REFRESH should be changed to CollectionEventKind.RESET. The adobe bug link mentions this.
Thanks for this solution. It saved me a lot of time. jwolff --- In [email protected], "Gregor Kiddie" <[EMAIL PROTECTED]> wrote: > > Found it ;) http://bugs.adobe.com/jira/browse/FLEXDMV-1334 > > > > I think the code below should work (untested and rough but you get the > idea) > > > > package com.inpses.util { > > > > import flash.events.Event; > > > > import mx.collections.HierarchicalData; > > import mx.events.CollectionEvent; > > import mx.events.CollectionEventKind; > > > > public class EventHierarchicalDataSource extends HierarchicalData > { > > > > public function > EventHierarchicalDataSource(value:Object=null) { > > super(value); > > } > > > > public override function set source( value : Object ) : void > { > > super.source = value; > > dispatchEvent( new CollectionEvent( > CollectionEvent.COLLECTION_CHANGE, false, false, > CollectionEventKind.REFRESH ) ); > > if ( value ) { > > value.addEventListener( > CollectionEvent.COLLECTION_CHANGE, dispatchSourceChangeEvent, false, 0, > true); > > } > > } > > > > private function dispatchSourceChangeEvent ( event : Event ) > : void { > > dispatchEvent( new CollectionEvent( > CollectionEvent.COLLECTION_CHANGE, false, false, > CollectionEventKind.REFRESH ) ); > > } > > > > } > > } > > > > Gregor Kiddie > Senior Developer > INPS > > Tel: 01382 564343 > > Registered address: The Bread Factory, 1a Broughton Street, London SW8 > 3QJ > > Registered Number: 1788577 > > Registered in the UK > > Visit our Internet Web site at www.inps.co.uk > <blocked::http://www.inps.co.uk/> > > The information in this internet email is confidential and is intended > solely for the addressee. Access, copying or re-use of information in it > by anyone else is not authorised. Any views or opinions presented are > solely those of the author and do not necessarily represent those of > INPS or any of its affiliates. If you are not the intended recipient > please contact [EMAIL PROTECTED] > > ________________________________ > > From: [email protected] [mailto:[EMAIL PROTECTED] On > Behalf Of Gregor Kiddie > Sent: 06 May 2008 15:58 > To: [email protected] > Subject: RE: [flexcoders] questionfor AdvancedDataGrid? > > > > "I have the following question about AdvancedDataGrid?" > > Yeah, there is a closed bug about it (can't find the number just now!) > > The Grouping and Hierarchical dataproviders don't throw events when > their contents change, so the binding never fires with what you have > there. > > The workaround is to subclass the GroupingCollection and manually throw > the event when it changes. > > > > I'll try and find the bug number... > > > > Gk. > > Gregor Kiddie > Senior Developer > INPS > > Tel: 01382 564343 > > Registered address: The Bread Factory, 1a Broughton Street, London SW8 > 3QJ > > Registered Number: 1788577 > > Registered in the UK > > Visit our Internet Web site at www.inps.co.uk > <blocked::http://www.inps.co.uk/> > > The information in this internet email is confidential and is intended > solely for the addressee. Access, copying or re-use of information in it > by anyone else is not authorised. Any views or opinions presented are > solely those of the author and do not necessarily represent those of > INPS or any of its affiliates. If you are not the intended recipient > please contact [EMAIL PROTECTED] > > ________________________________ > > From: [email protected] [mailto:[EMAIL PROTECTED] On > Behalf Of markflex2007 > Sent: 06 May 2008 14:55 > To: [email protected] > Subject: [flexcoders] questionfor AdvancedDataGrid? > > > > Hi, > > I have the following question about AdvancedDataGrid? >

