In Flex AdvancedDatGrid we do a lot of grouping. Most columns are the same for parents and children, so I would like to show the first value of the group as a summary, not MAX, MIN or AVG
This code works with numeric, but not textual values (without a commented line, you get NaN):
private function firstValue(itr:IViewCursor,field:String, str:String=null):Object {
XML:
(mx:GroupingField name="Offer") (mx:summaries) (mx:SummaryRow summaryPlacement="group") (mx:fields) (mx:SummaryField dataField="OfferDescription" label="OfferDescription" summaryFunction="firstValue"/) (mx:SummaryField dataField="OfferID" label="OfferID" summaryFunction="firstValue"/) (/mx:fields) (/mx:SummaryRow) (/mx:summaries) (/mx:GroupingField)
OfferID Correct, OfferDescription no.
Dave source share