More in this section

Forums / Developing with Sitefinity / Setting selected items in a FlatSelector

Setting selected items in a FlatSelector

2 posts, 0 answered
  1. Jack
    Jack avatar
    7 posts
    30 Oct 2013
    29 Apr 2014
    Link to this post


     I've got a FlatSelector in my widget's designer .ascx. This has AllowMultipleSelection set to 'true'. So when i click on the select button, in the flatselector, i can choose multiple items. I am then saving these multiple items as a string of guids (See here). If i then go back to edit what i've already selected the flatselector will always open in it's default state with no items selected. 

    So is there a way to pass in values to a flatselector so they will be 'selected' when i go back and view them? I can see in the designer .js there is the jquery().dialog() being set up but i cant see where i can pass in data or even if i can.


  2. Nikola Zagorchev
    Nikola Zagorchev avatar
    424 posts
    19 Apr 2017
    01 May 2014
    Link to this post
    Hi Jack,

    It is important that you pass correct data to the flat selector so it can bind it and show the already selected and saved items, unless it will show empty (no items). If you refer to the SelectedItems tab in the opened dialog of the flat selector, you will see there only the currently selected items and when the dialog is closed, they are cleaned. This is the dialog tab default behavior.
    I hope this info is useful.

    Nikola Zagorchev
    Do you want to have your say in the Sitefinity development roadmap? Do you want to know when a feature you requested is added or when a bug fixed? Explore the Telerik Sitefinity CMS Ideas&Feedback Portal and vote to affect the priority of the items
2 posts, 0 answered