Hi,
I'm using a RadGridView and RadDataPager together:
The grid also has a checkbox select column.
Desired behaviour:
The user selects a number of items on one page.
User navigates to another page.
User navigates back to previous page and the previously selected items are still shown as selected.
The following code was working using Telerik.Windows.Controls.GridView.dll version 2010.1.422.35:
}
Since upgrading to Telerik.Windows.Controls.GridView.dll version 2012.2.607.40, the above event "Items_PageChanged" fails to fire.
NB. The method "SelectGloballySelectedItems" compares the items on the currently displayed page with those which have been previously selected across multiple pages and reselects them.
Any idea why the event isn't firing or is there a new way to achieve the desired functionality.
Thanks,
Mark
I'm using a RadGridView and RadDataPager together:
<
telerik:RadGridView
Margin
=
"0,0,0,0"
Name
=
"grdGeneralPayments"
SelectionMode
=
"Extended"
ShowGroupPanel
=
"False"
ShowColumnFooters
=
"False"
CanUserSelect
=
"False"
CanUserInsertRows
=
"False"
CanUserDeleteRows
=
"False"
IsSynchronizedWithCurrentItem
=
"False"
MouseDoubleClick
=
"grdGeneralPayments_MouseDoubleClick"
SelectionChanged
=
"grdGeneralPayments_SelectionChanged"
Filtering
=
"grdGeneralPayments_Filtering"
Filtered
=
"grdGeneralPayments_Filtered"
ScrollViewer.VerticalScrollBarVisibility
=
"Auto"
ScrollViewer.HorizontalScrollBarVisibility
=
"Auto"
DockPanel.Dock
=
"Top"
>
</
telerik:RadGridView
>
<
telerik:RadDataPager
Name
=
"radDataPager"
Margin
=
"0,0,0,0"
DockPanel.Dock
=
"Bottom"
PageSize
=
"10"
Source
=
"{Binding Items, ElementName=grdGeneralPayments}"
PageIndexChanging
=
"radDataPager_PageIndexChanging"
/>
The grid also has a checkbox select column.
//Because grid columns are auto generated we need to add the select row checkbox column ourselves.
GridViewSelectColumn selectCol = new GridViewSelectColumn();
selectCol.Name = "Select";
//Put select row checkbox column on LHS of the grid.
this.grdGeneralPayments.Columns.Insert(0, selectCol);
Desired behaviour:
The user selects a number of items on one page.
User navigates to another page.
User navigates back to previous page and the previously selected items are still shown as selected.
The following code was working using Telerik.Windows.Controls.GridView.dll version 2010.1.422.35:
public ApproveGeneralPayments()
{
InitializeComponent();
this.grdGeneralPayments.Items.PageChanged += new EventHandler<
EventArgs
>(Items_PageChanged);
private void Items_PageChanged(object sender, EventArgs e)
{
this.SelectGloballySelectedItems();
this.changingPage = false;
}
Since upgrading to Telerik.Windows.Controls.GridView.dll version 2012.2.607.40, the above event "Items_PageChanged" fails to fire.
NB. The method "SelectGloballySelectedItems" compares the items on the currently displayed page with those which have been previously selected across multiple pages and reselects them.
Any idea why the event isn't firing or is there a new way to achieve the desired functionality.
Thanks,
Mark