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

Repopulating dropdown after OnClick event

2 Answers 467 Views
DropDownList
This is a migrated thread and some comments may be shown as answers.
David
Top achievements
Rank 1
David asked on 09 May 2016, 01:45 PM
I am attempting to repopulate the dropdownlist with new items when a user clicks on a barchart. For the sake of the demo I made it simple html links instead of the barchart. Once they click on a link/bar the dropdownlist will repopulate with items in the new area. The old items will also be removed. The included example is close to what should occur but the dropdownlist's data is not being cleared and updated after clicking on the link. Please advise.

2 Answers, 1 is accepted

Sort by
0
Accepted
Alexander Valchev
Telerik team
answered on 11 May 2016, 08:24 AM
Hello David,

In order to change dynamically the data of the DropDownList widget please use its setDataSource method.

Regards,
Alexander Valchev
Telerik
 
Join us on our journey to create the world's most complete HTML 5 UI Framework - download Kendo UI now!
 
0
David
Top achievements
Rank 1
answered on 11 May 2016, 09:46 PM
Thanks that's exactly what I was looking for.
Tags
DropDownList
Asked by
David
Top achievements
Rank 1
Answers by
Alexander Valchev
Telerik team
David
Top achievements
Rank 1
Share this question
or