I've a functionality where I need to have a combo box column in my Grid. The below are my code that I use to have a combo column
columns.Template(o => Html.ActionLink(o.Description !=
string.Empty ? o.Description : "No Description", "ContactView", new { OpportunityID = o.OpportunityID })).Title("Description").Width(200);
columns.Bound(o => o.DueDate).Title(
"DueDate").Width(70);
columns.Bound(o => o.PriorityName).Title(
"Priority").Width(60);
columns.Bound(o => o.TypeName).ClientTemplate(Html.Telerik().DropDownList().Name(
"Type").BindTo(new SelectList((IEnumerable)SessionHandler.CRMTasksType, "Value", "Text")).ToHtmlString()).Title("Type").Width(60);
columns.Bound(o => o.StatusName).ClientTemplate(Html.Telerik().DropDownList().Name(
"StatusName").BindTo(new SelectList((IEnumerable)SessionHandler.CRMTasksStatus, "Value", "Text")).ToHtmlString()).Title("Status").Width(60);
columns.Bound(o => o.Comments).Title(
"Comments").Width(130);
}).ClientEvents(events => events.OnEdit(
"onEdit")).Editable(editing => editing.Mode(GridEditMode.InCell).DefaultDataItem(new HomeFrontCRM.Web.UI.Models.OpportunityTaskModels { DueDate = DateTime.Today })).Pageable().Sortable().Scrollable(scrolling => scrolling.Height(100)).Reorderable(reorder => reorder.Columns(true)).Resizable(resizing => resizing.Columns(true)).HtmlAttributes(new { style = " font-family:arial; font-size: .7em;" }).Render();
The Problem is, I'm able to see the Combo Box but when I click on the cell, it changes to a Text Box. Can you one suggest on this ?