need to return to page to selected item

Thread is closed for posting
2 posts, 0 answers
  1. Toby
    Toby avatar
    1 posts
    Member since:
    Feb 2011

    Posted 18 Aug 2011 Link to this post

        I have had good luck with loopinglist in most regards, but a couple behaviour anomolies have cropped up. In one case, i have created a horizontal, text-based loopinglist with 10 items. The user can select items first and the selection is verified in code and the selection stashed in isolated storage with no issue. The user then can leave the page to add another item or go to the settings page, for example. Inmy loop, 3 items are on screen at any given time. Upon return i call up the selected item and rebuild the looping list and 'seed' src.ItemNeeded with selectedItem-2, selectedItem-1, and selectedItem and set loop.SelectedIndex=selectedItem. This seems to work to get the page reloaded and the loop in the right spot and correct item selected. And in fact this does work for all my items except the 2nd item in the list (i.e.item[1]). When this item was the selected item and we return to the page, the display selects the [0] item and doesn't center the loop items as it does the rest of them.
    Here's the code to 'seed' the ItemNeeded. labelLocations is location in array so [0-9]. locationListItemCount is the toal number of items in the list, so 10. So if i selected item [1], then labelLocations would start at [9] then go to [0], then [1]. This seems to center item [1] on the loop.

    src.ItemNeeded += (sender2, args) =>


    args.Item =


    new LoopingListDataItem(locationListItem[labelLocations]);



    if (labelLocations > (locationListItemCount - 1)) { labelLocations = (locationListItemCount - labelLocations); }//wrap past array size logic


  2. Deyan
    Deyan avatar
    2147 posts

    Posted 23 Aug 2011 Link to this post

    Hello Toby,

    Thanks for contacting us and for reporting this issue.

    In order to be able to directly investigate the case, we would kindly like to ask you to prepare a very simple Windows Phone 7 app that demonstrates the undesired behavior and send it to us by opening a new support ticket. In this way we will take a look at the code, debug it and find the reason for this behavior.

    Thanks for your time.

    Kind regards,
    the Telerik team

    Thank you for being the most amazing .NET community! Your unfailing support is what helps us charge forward! We'd appreciate your vote for Telerik in this year's DevProConnections Awards. We are competing in mind-blowing 20 categories and every vote counts! VOTE for Telerik NOW >>

Back to Top