One option is to apply the sort on your collection and pull the records in out, 
sort, re-set to datagrid. this is a bit trickier then you might think but its 
possible.

So AC.sort = someSort;
var orderedRows:Array = AC.source;

grid.dataProvider = new AC(orderedRows)

Something along those lines.

Another option might to be 'remember' the original order before sort in grid 
starts; in the sortHandler where u can intercept before sort happens. Once u 
have the ordered list, use that to help your sort comparer;

customSortComparer(row1, row2) : boolean

 if(row1 == row2)
   checkAgainstCurrentOrder(row1,row2);

--- In [email protected], "Sneha" <sneha_mod...@...> wrote:
>
> Hi,
> 
> I am using in-built sort functionality provided by AdvancedDatagrid.
> 
> I have multiple columns and suppose I have 10 rows. All 10 rows have the same 
> data in one column. 
> 
> If I sort on that column, then it sorts and the data in other columns which 
> is different is also being sorted (reshuffled).
> 
> My requirement is if I am sorting on a column with same data, it should not 
> sort the data in other columns.
> 
> To understand it better, check the link menioned below 
> http://www.adobesystems.ca/devnet/flex/quickstarts/using_adg_control.html.
> 
> In the above link mentioned, if you click on region column, other columns 
> like territory or actual will change the values i.e. the rows gets reshuffled.
> 
> This should not happen as we are sorting on a column which has same values. 
> Does anybody know how this can be handled in Flex 3 for AdvancedDataGrid.  
> 
> Thanks in advance.
> 
> Thank you
> Sneha
>


Reply via email to