RadDataPager UI bug on PageIndexChanging cancel

3 posts, 1 answers
  1. Mike
    Mike avatar
    8 posts
    Member since:
    Jul 2010

    Posted 06 Jul 2010 Link to this post


    I'm using SilverLight 4.0 with a RadDataPager bound to a RadDataGrid to display and edit some data. When the user edits data and then tries to move to a different page without saving, I've got an event handler for the PageIndexChanging event of the pager displaying a modal dialog with yes/no/cancel options appearing. If the user selects cancel, I simply set the eventargs' cancel property to true. This works fine, and the page does not change, but on the UI it will show the new page is selected, even though it is not.

    For example, if the user is on page one, edits the data, clicks page two, selects cancel, then the control remains on page one (and the data is never changed, nor are the unsaved changes lost) but the pager elements on the UI show page two as selected.

    Are there any fixes or workarounds for this issue? Thanks.
  2. Answer
    Veselin Vasilev
    Veselin Vasilev avatar
    2992 posts

    Posted 07 Jul 2010 Link to this post

    Hi Mike,

    To my regret we discovered this problem recently and could not manage to fix it for the official Q2 version scheduled for the beginning of the next week. We will try to fix it for one of the internal builds after the release or for the SP1.

    As a workaround you can try to set again the Source property of the dataPager in case you have canceled the event:

    private void dataPager_PageIndexChanging(object sender, Telerik.Windows.Controls.PageIndexChangingEventArgs e)
       if (should_cancel_the_event)
        e.Cancel = true;
        dataPager.Source = Person.GetPeople();

    Sincerely yours,
    the Telerik team
    Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items
  3. Mike
    Mike avatar
    8 posts
    Member since:
    Jul 2010

    Posted 08 Jul 2010 Link to this post

    Hi Veskoni,

    Thanks for your reply. Setting my data pager's source to null then immediately rebinding it worked around the bug quite neatly.
Back to Top