Grid Flex


    xmlns:mx="http://www.adobe.com/2006/mxml" 
    xmlns:s="library://ns.adobe.com/flex/spark"
    creationComplete="handleCreationComplete();">
    
    
            
                
                
            

            
                
                    
                

            

    
    
    
        
            import mx.collections.Grouping;
            import mx.collections.GroupingField;
            
            private function handleCreationComplete():void
            {
                groupingCollection.refresh();
            }
            
            private function createGrouping( field:String ):void 
            {
                var groupingInst:Grouping = new Grouping();
                groupingInst.fields = [new GroupingField( field )];
                groupingCollection.grouping = groupingInst;
                groupingCollection.refresh(false);
            }