This is a migrated thread and some comments may be shown as answers.

Keeping selected items

1 Answer 24 Views
MultiSelect
This is a migrated thread and some comments may be shown as answers.
Brad
Top achievements
Rank 1
Brad asked on 02 May 2014, 09:30 PM
Is there any way to prevent the removal of an item from the select list when a user selects it and maintain the order of the select list?

1 Answer, 1 is accepted

Sort by
0
Alexander Popov
Telerik team
answered on 06 May 2014, 10:46 AM
Hi Brad,

I already answered to this query in support ticket #816306. I will post my reply here as well, in case anyone else stumbles on the same scenario:
Although this behavior is not supported out of the box it could be achieved using a custom solution. For example:
  • Subscribe to the MultiSelect's open event
  • Once the event is triggered get the instance of the popup list
  • Find all li elements and set their display CSS attribute to its default value (selected items' display is set to none by the widget)

Here is an example illustrating the above approach - I hope it helps.

Regards,
Alexander Popov
Telerik
 

Check out the Telerik Platform - the only platform that combines a rich set of UI tools with powerful cloud services to develop web, hybrid and native mobile apps.

 
Tags
MultiSelect
Asked by
Brad
Top achievements
Rank 1
Answers by
Alexander Popov
Telerik team
Share this question
or