There is really no documentation to speak of on the Radgrid OnGroupExanded and OnGroupCollapsed client events so I'm hoping I can get some help from the community.
Scenario: I have Client Side Grouping set on a grid and I need to be able to persist what groups were expanded/collapsed between rebinds so I can't use server side itemcommand event because nothing fires sever side when you use client side grouping.
Approach: I am attaching two javascript functions to handle the two different events and fire a ajaxRequest to the server side with the index of the row expanded/collapsed. I have all the server side hash tables set up based on a forum example and will use the grid.item[itemIndex].expanded = true or false to rehydrate on page load.
Problem: I don't know how to get anything from the two client events to determine what item index was expanded/collapsed. The eventArgs are supposed to be a gridDataItem object but I've had no success accessing properties.
Question: How do I get the index of the expanded/collapsed row client side? See below javascript function.
Scenario: I have Client Side Grouping set on a grid and I need to be able to persist what groups were expanded/collapsed between rebinds so I can't use server side itemcommand event because nothing fires sever side when you use client side grouping.
Approach: I am attaching two javascript functions to handle the two different events and fire a ajaxRequest to the server side with the index of the row expanded/collapsed. I have all the server side hash tables set up based on a forum example and will use the grid.item[itemIndex].expanded = true or false to rehydrate on page load.
Problem: I don't know how to get anything from the two client events to determine what item index was expanded/collapsed. The eventArgs are supposed to be a gridDataItem object but I've had no success accessing properties.
Question: How do I get the index of the expanded/collapsed row client side? See below javascript function.
function
CollapseGroup(sender, eventArgs) {
var itemIndex = eventArgs (what to do here?)
$find(
"ctl00_RadAjaxManager1").ajaxRequest("Collapsed~" + itemIndex);
}