RadComboBox using templates
I have a RadComboBox using a checkbox and a label... Now you know how it shows the items being checked at the top, how it separates them by commas .. i.e
If the values are
[ ]Car
[ ]Bicyle
[ ]Trucks
As I select or check each.. it starts adding them like this..
Car,Bicycle,Trucks
otherwise if nothing is picked it shows "All Types
开发者_如何学编程".
Well this is working fine but I am stuck when coming back to the page. When I come back to the page from some other page the RadComboBox has the items checked.. but the line where it is supposed to have
Car, Bicycle, Trucks
does not show, it defaults to the first item "Car" and it does not show the whole string. This is pulling the values from a database and it is bringing the correct values as well as marking them check but.. How do I make it so that when I comeback that string is there in the combo box?
See examples at the telerik page for more info.
http://demos.telerik.com/aspnet-ajax/combobox/examples/functionality/templates/defaultcs.aspx
Figured it out, Just added a ddl.SelectedItem.Text = mystringVal;
and that was it.
精彩评论