I'm doing Server Filtering on a combobox on selecting a school. School may have thousands of row. I have it working fine but when I go back into Edit mode I was to display the Template to the selected saved record. I have what should be displayed as well as the ID in the ViewModel. I tried Value and I tried do it in javascript but can't find a way.
@(Html.Kendo().ComboBox()
.Name("SchoolId")
.Placeholder("Select School")
.DataTextField("schoolName")
.DataValueField("schoolId")
.HtmlAttributes(new { @class = "form-control" })
.Filter(FilterType.Contains)
.AutoBind(false)
.MinLength(3)
.DataSource(source =>
{
source.Read(read =>
{
read.Action("GetSchools", "User");
read.Type(HttpVerbs.Get);
})
.ServerFiltering(true);
})
.Template("#: data.schoolName # (#: data.schoolCity #, #: data.schoolState #)")
)