I use this code with an ArrayCollection dataProvider.
I'm using multiple cell selection as well, but you can customize as you
need:

var ac:ArrayCollection = dataProvider as ArrayCollection;

         for(var i:Number = 0; i < selectedCells.length; i++) {
                var cell:Object = selectedCells[i];
                var data:Object = ac.getItemAt(cell.rowIndex);
                var dataField:String = columns[cell.columnIndex].dataField;

                data[dataField] = "";
                ac.itemUpdated(data, dataField);
            }

aside, selectedIndex and selectedColumnIndex should give you the indices you
need to retrieve a itemRenderer or a datapovider's object



2008/7/25 whatabrain <[EMAIL PROTECTED]>:

>   How can you tell which item in the dataProvider was clicked in an
> AdvancedDataGrid, when using HierarchicalData as the dataProvider?
>
> I tried using the typical DataGrid method, of saving off the item index
> in itemRollOver, and using it to determine the index of the clicked
> item. However, with AdvancedDataGrid, the row index isn't particularly
> relevant. Or is there some way to convert the row index to the actual
> clicked item in the dataProvider?
>
>  
>

Reply via email to