Obtaining the current selected Multi Select text values using jquery on a virtualised list

1 Answer 4838 Views
MultiSelect
Jaesoon
Top achievements
Rank 1
Jaesoon asked on 30 Dec 2015, 12:51 PM

I'm trying to create a string using the text values in the multi select list using Jquery but I'm having trouble trying to get the selected value's text fields.

 

I can see that theres a value function which returns the ID's of the list (i.e. DataValueField?) but not the text fields (i.e. DataTextField?).

I've had a look at the datasource to see if i can iterate through that instead and find the text values that i need but as im virtualising the multi select list, im only getting a limited subset of the items i need.

 

Is there any way to get the selected items using Jquery? It seems like such an easy task to do as the objects are already displayed on screen but i cannot figure out how to access them.

 

Thanks

Jaesoon
Top achievements
Rank 1
commented on 31 Dec 2015, 01:49 AM

Alright so i've figured i can get the currently selected items by accessing the ID of the multi select list and getting the innerText of the values.

 

However, why is it when anything's selected on the screen, the font gets all capitalised? Is there any way to prevent this from happening? 

 

I would like the text values just how they show on the drop down, not capitalised when they're selected.

 

Thanks

1 Answer, 1 is accepted

Sort by
0
Georgi Krustev
Telerik team
answered on 04 Jan 2016, 10:07 AM
Hello Jaesoon,

The MultiSelect widget has a dataItems method, which will return a list of the selected data items. You can use them to retrieve the selected text: The capitalized text is related to the particular Kendo theme used in your project. You can control the text styling using CSS. You can find more details about the Kendo styling here:
Regards,
Georgi Krustev
Telerik
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 Feedback Portal and vote to affect the priority of the items
Tags
MultiSelect
Asked by
Jaesoon
Top achievements
Rank 1
Answers by
Georgi Krustev
Telerik team
Share this question
or