I am using a GroupingCollection to bind my advanceddatagrid. I have used groupingcollection to group the data by date.
Now I need to select the data in the datagrid through the code. Does anyone have any idea as to how to do this? I need to loop through the adg’s dataprovider and select the item that matches the criteria for the selection.
Please advise
Thanks 🙂
Okay, depending on how the question in interpreted, this code will find the items that match the grouping year that is selected. I added a
click=findStuff(event)to themx:AdvancedDataGrid, as shown here:Note that first I get the GroupingCollection from the AdvancedDataGrid dataProvider, then I get the items from the GroupingCollection. These could be combined into one step, but this way is more readable for the example. Not knowing exactly what data you’re looking for I just grab the
namefield from the dataitembut there’s no reason you couldn’t grab the wholeitem.Hopefully this is a step in the right direction for you.