Telerik Forums
UI for ASP.NET MVC Forum
1 answer
14 views

Hi,
   I am working with Kendo UI grid in ASP .NET MVC using an EditorTemplate with ComboBoxFor inside the grid.

Issue description

  • The combobox appears inside the grid edit mode.
  • When I click the dropdown , it shows "No data found"
  • The server side action method is not being hit at all.
  • No JS error
  • Using same server endpoint DropdownListFor works correctly and loads data

Sample code

@model Department

@(Html.Kendo()
.ComboBoxFor(m=>m)
.DataValueField("departmentId")
.DataTextField("departmentName")
.DataSource(ds=>ds.Read(read=>read.Action("GetDepartments", "Home")))
)

Anton Mironov
Telerik team
 answered on 02 Feb 2026
2 answers
26 views

Hi,

I am exporting excel from kendo grid in client side with default Excel() method.

When I am trying to read any exported excel from JavaScript I am not able to read any excel data, but when I open the excel file and click on save button, then going forward that excel I am able to read from JavaScript. Below are the codes used for export and import. 

Export Code:

function exportData(gridName) {
    var grid = $("#" + gridName).data("kendoGrid");
    var pageSize = grid.dataSource._pageSize;
    var dataSourceTotal = grid.dataSource.total();
    grid.dataSource.pageSize(dataSourceTotal);
    grid.saveAsExcel();
    grid.dataSource.pageSize(pageSize); // Reset page size after a delay
}

Import Code :

const reader = new FileReader();
var mappedExcelRecords = [];

// The callback is executed here, once the load event fires
reader.onload = function (event) {
    var data = event.target.result;
    var workbook = XLSX.read(data, {
        type: 'binary'
    });

    var jsonExcelRecords;

    workbook.SheetNames.forEach(function (sheetName) {
        jsonExcelRecords = XLSX.utils.sheet_to_row_object_array(workbook.Sheets[sheetName])
    })

In jsonExcelRecords variable I am getting all the excel data if the excel is open and saved once but when the excel is exported from the kendo grid and trying to import then the below code doesn't get any data from excel.

jsonExcelRecords = XLSX.utils.sheet_to_row_object_array(workbook.Sheets[sheetName])

Please look into this issue and feel free to ask if you need any new information.

 

abdul
Top achievements
Rank 2
Iron
Iron
Iron
 answered on 31 Jan 2026
1 answer
32 views
Hi, I'm asking about an answer posted in the Sorting Grid on Editor Template column post back in 2017.  The answer was from Georgi and here is the excerpt: 

public ActionResult Read([DataSourceRequest] DataSourceRequest request) { // Check if any sorts have been applied.if (request.Sorts != null) { // Loop through each sort.foreach (var sort in request.Sorts) { // Check if the Category column is being sortedif (sort.Member == "Category") { // Sort by the CategoryName instead of the Object. sort.Member = "Category.CategoryName"; } } } }

 

My grid column coincidentally also has to do with categories. I tried adding the above code to my read method and it doesn't work. When I click on the header to sort the column it doesn't automatically initiate a read call so I'm not sure how this could work. I guess I'm missing something.

My grid definition:

@(
Html.Kendo().Grid<LookupItem>()
    .Name("LookupList")
    .Columns(columns =>
    {
        columns.Bound(m => m.Id).Hidden(true);
        columns.Bound(m => m.CategoryListItem).ClientTemplate("#: CategoryListItem.CategoryName #").EditorTemplateName("LookupCategoryDropDown").Width("25%"); ;
        columns.Bound(m => m.Name).Width("25%");
        columns.Bound(m => m.Value).Width("15%");
        columns.Bound(m => m.AlternativeValue).Width("15%");
        columns.Command(command => { command.Edit(); command.Destroy(); }).Width(200);
    })
    .ToolBar(toolbar => { toolbar.Create().Text("Add New Lookup Item"); })
    .Editable(editable => editable.Mode(GridEditMode.InLine).DisplayDeleteConfirmation("Are you sure you want to delete this item?"))
    .Sortable()
    .Scrollable()
    .Filterable(filterable => filterable.Extra(false))
    .Pageable()
    .DataSource(dataSource => dataSource
        .Ajax()
        .PageSize(50)
        .ServerOperation(false)
        .Model(model =>
        {
            model.Id(m => m.Id);
            model.Field(m => m.Category);
            model.Field(m => m.Name);
            model.Field(m => m.Value);
            model.Field(m => m.AlternativeValue);

        })
        .Read(read => read.Action("Lookup_Read", "Lookup"))
        .Create(create => create.Action("Lookup_Create", "Lookup"))
        .Update(update => update.Action("Lookup_Update", "Lookup"))
        .Destroy(read => read.Action("Lookup_Delete", "Lookup"))
    )

My Controller Read Method:

 public async Task<IActionResult> Lookup_Read([DataSourceRequest] DataSourceRequest request)
 {
     if (request.Sorts != null)
     {
         // Loop through each sort.
         foreach (var sort in request.Sorts)
         {
             // Check if the Category column is being sorted
             if (sort.Member == "CategoryListItem")
             {
                 // Sort by the CategoryName instead of the Object.
                 sort.Member = "CategoryListItem.CategoryName";
             }
         }
     }
     var model = await _service.GetAllLookupTypesAsync();
     var result = model.ToDataSourceResult(request);
     return Json(result);

 }               
Anton Mironov
Telerik team
 answered on 27 Jan 2026
1 answer
37 views

Hi,

We have a requirement, where we have a kendo grid, from the grid columns we need one or multiple columns as a dropdown/combobox.

Along with the above requirement we have the below requirements. 

1. Grid column with Dropdown/Combobox should work when paste in grid
2. Export also should work with dropdown/combobox columns.

To add new rows in the grid, we have to copy the rows from excel and paste in the grid, so after the paste all the new records should appear even in the dropdown/combobox field. The export is a client side export. 

And for the grid we have a button for exporting the grid data in excel. If for specific column which will be dropdown/combobox which will be of complex type then after export how that column will display in the excel.

 

Note: We have already tried with dropdownlist in the grid. We created a UI component and user that inside EditorTemplateComponentName

in the cshtml file. We are able to render the dropdown for that particular column inside the grid. But the problem is with dropdownlist column when we try to copy and paste records from excel to grid, paste is not working for dropdown column.

And also the dropdown column is a complex type so when we export the grid, the dropdown column value is not render in the excel file.

So, we are thinking to achieve the above requirements with a combo box, please provide the solution for the above requirements.

Eyup
Telerik team
 answered on 23 Jan 2026
1 answer
95 views

I have a asp.net mvc kendo grid with Edit option in each row, on click it brings the data from Editor Template(its having a kendo dropdown in it) I have implemented CSP globally. Grid having Deferred() in it.  Grid works fine with its basic get records.

After CSP . Edit click is not opening the popup. Shows console error with invalid template. 

 

followed by the entire page html code.

How to eliminate this. How to use Edit with CSP.

Grid Example:

@(Html.Kendo().Grid((IEnumerable<test>)Model)
    .Name("test")
    .DataSource(datasource => datasource.Ajax().Read(read => read.Action("GetRecords", "Test").Type(HttpVerbs.Get)))
    .Columns(columns =>
    {
        columns.Command(command => { command.Edit().Text("Edit"); }).Width(75);
        columns.Bound(p => p.Id).Title("ID").Width(130);
        columns.Bound(p => p.Name).Title("Name").Width(130);
        columns.Bound(p => p.Date).Title("Date").Width(150);
    })
     .Editable(editable =>
 {
     editable.Mode(GridEditMode.PopUp).TemplateName("Edit_Details");
 })
    .Pageable()
    .Sortable()
    .Scrollable()
    .DataSource(dataSource => dataSource
        .Ajax()
        .Model(model =>
        {
            model.Id(p => p.Id);
        })
         .Update(update => update.Action("EditDetails", "Test").Type(HttpVerbs.Post))
    )
    .Deferred()
)

 

 

Thanks,

Anupriya. R

 

Nikolay
Telerik team
 answered on 08 Jan 2026
1 answer
47 views

We have a column of type text, and want to change the default filter from 'equals' to 'contains'.


This doesn't seem to have any effect: 

.Filterable(f => f.Cell(c => c.Operator("contains")))


This does not seem to work in the context of the MVC Grid: jQuery Set the Default Filter Operator in the Grid - Kendo UI for jQuery

Eyup
Telerik team
 answered on 07 Nov 2025
1 answer
127 views

Hi,

I have a kendo grid and in the page load kendo grid automatically have a new empty row. When we click on the + icon then it should create multiple rows in the grid.

 

The above functionality is working fine, but when we do a filter on any of the column then on filter click button it should display filtered row along with new empty row.

After click on filter button the empty row is not creating. I tried the below code on click on filter button it fires the Filter event but  

its not creating the empty row. Can you please let me know how to add a new empty row on click of filter button.

.Events(ev => ev.Filter("onFiltering"))

function onFiltering() {
    var gridName = "grid1";
    var grid = $("#" + gridName).data("kendoGrid");

if (grid && grid.dataSource) {
    grid.dataSource.cancelChanges();
    var newRow = { field: "NewRow", Value: 0 };
    grid.dataSource.add(newRow);
}

}

Ivaylo
Telerik team
 answered on 01 Oct 2025
1 answer
95 views
Hello everyone
i have to create some cypress tests and figured out that nested grid components like the header date time filters do not have any ids or data-role-ids.
is there a way to "enable" them? 
i can find components searching by Title (like  $(e.container).find('select[title="Operator"]'); or $(e.container).find('select[title="Additional operator"]');) but it's not 100% safe

Anton Mironov
Telerik team
 answered on 25 Sep 2025
0 answers
88 views

Hi,

I have a strict CSP implemented in the Program.cs file, after that when I verified the browser developer tool then I can see the get API is called 2 times.

Can you please let me know why this get API is called 2 times. 

When I analyze I found that Kendo Panelbar Select event is called twice so internally the Get API is called twice.

@(Html.Kendo().PanelBar()
        .Name("panelbar")
        .ExpandMode(PanelBarExpandMode.Multiple)
        .Events(ev => ev.Select("OnSelect_Panel"))
        .Items(panelbar =>
        {
          panelbar.Add().Text("Test Panel");
        })


function OnSelect_Panel(sender) {

}

Inside the OnSelect_Panel() method is calling twice so the GET API also called twice. How can I restrict to one API call.

Note: Without strict CSP OnSelect_Panel() is called once but with strict CSP it called twice.

 

abdul
Top achievements
Rank 2
Iron
Iron
Iron
 updated question on 19 Sep 2025
1 answer
78 views

I have two draggable grids, but the second has no drop point, just a circle with a line through it. Can you tell me why the second grid allows me to drag the row but no where to drop?

 

                        // QUESTIONS
                        tab.Add().Selected(true).Text("Questions").Content(@<text>
                        @(Html.Kendo().Grid<TemplateQuestionVM>()
                            .Name("AI_TemplateQuestionGrid")
                            .ToolBar(toolbar =>
                            {
                                if (Model.TemplateId != 0) toolbar.New("TemplateQuestionEdit", "Template Question", $"AI/TemplateQuestion/edit?parentId={Model.TemplateId}");
                                toolbar.SuperSearchWindow("TemplateEdit", "AI_TemplateQuestionGrid");
                            })
                            .Height(600)
                            .DataSource(dataSource => dataSource
                                .Ajax()
                                .Sort(s => s.Add("Sequence"))
                                .Read(read => read.Action("Read", "TemplateQuestion", new { parentId = Model.TemplateId }).SuperSearchWindow("TemplateEdit", "AI_TemplateQuestionGrid"))
                                .Model(m => m.Id(f => f.TemplateQuestionId))
                            )
                            .Columns(columns =>
                            {
                                columns.Bound(c => c.TemplateQuestionId).Width(1).Title("").Filterable(false);
                                columns.Bound(c => c.Sequence).Width(80).Title("Seq").Filterable(false);
                                columns.Template("").Draggable(true).Width(80);
                                columns.Bound(c => c.QuestionName).Title("Question").Filterable(false);
                                columns.Bound(c => c.TemplateQuestionId).Edit("TemplateQuestionEdit", "Template Question", "AI/TemplateQuestion/edit/#=TemplateQuestionId#");
                            })
                            .Filterable()
                            .Scrollable()
                            .Sortable()
                            .Reorderable(order => order.Rows(true))
                            .Events(ev => { ev.RowReorder("function(e) { dragRow(e, 'AI_TemplateQuestion', 'TemplateId', " + Model.TemplateId + "); }"); })
                        )</text>);

                        // VARIABLES
                        tab.Add().Selected(false).Text("Variables").Content(@<text>
                        @(Html.Kendo().Grid<TemplateVariableVM>()
                            .Name("AI_TemplateVariableGrid")
                            .ToolBar(toolbar =>
                            {
                                if (Model.TemplateId != 0) toolbar.New("TemplateVariableEdit", "Template Variable", $"AI/TemplateVariable/edit?parentId={Model.TemplateId}");
                                toolbar.SuperSearchWindow("TemplateEdit", "AI_TemplateVariableGrid");
                            })
                            .Height(600)
                            .DataSource(dataSource => dataSource
                                .Ajax()
                                .Sort(s => s.Add("Sequence"))
                                .Read(read => read.Action("Read", "TemplateVariable", new { parentId = Model.TemplateId }).SuperSearchWindow("TemplateEdit", "AI_TemplateVariableGrid"))
                                .Model(m => m.Id(f => f.TemplateVariableId))
                            )
                            .Columns(columns =>
                            {
                                columns.Bound(c => c.TemplateVariableId).Width(1).Title("").Filterable(false);
                                columns.Bound(c => c.Sequence).Width(80).Title("Seq").Filterable(false);
                                columns.Template("").Draggable(true).Width(80);
                                columns.Bound(c => c.VariableCode).Width(200).Title("Variable").Filterable(false);
                                columns.Bound(c => c.VariableName).Title("Name").Filterable(false);
                                columns.Bound(c => c.VariableType).Width(200).Title("Type").Filterable(false);
                                columns.Bound(c => c.TemplateVariableId).Edit("TemplateVariableEdit", "Template Variable", "AI/TemplateVariable/edit/#=TemplateVariableId#");
                            })
                            .Filterable()
                            .Scrollable()
                            .Sortable()
                            .Reorderable(order => order.Rows(true))
                            .Events(ev => { ev.RowReorder("function(e) { dragRow(e, 'AI_TemplateVariable', 'TemplateId', " + Model.TemplateId + "); }"); })
                        )</text>);
Anton Mironov
Telerik team
 answered on 18 Sep 2025
Narrow your results
Selected tags
Tags
General Discussions
Scheduler
DropDownList
Chart
Editor
TreeView
DatePicker
ComboBox
Upload
MultiSelect
ListView
Window
TabStrip
Menu
Installer and VS Extensions
Spreadsheet
AutoComplete
TreeList
Gantt
PanelBar
NumericTextBox
Filter
ToolTip
Map
Diagram
Button
PivotGrid
Form
ListBox
Splitter
Application
FileManager
Sortable
Calendar
View
MaskedTextBox
PDFViewer
TextBox
Toolbar
MultiColumnComboBox
Dialog
DropDownTree
Checkbox
Slider
Switch
Notification
Accessibility
ListView (Mobile)
Pager
ColorPicker
DateRangePicker
Wizard
Security
Styling
Chat
DateInput
MediaPlayer
TileLayout
Drawer
SplitView
Template
Barcode
ButtonGroup (Mobile)
Drawer (Mobile)
ImageEditor
RadioGroup
Sparkline
Stepper
TabStrip (Mobile)
GridLayout
Badge
LinearGauge
ModalView
ResponsivePanel
TextArea
Breadcrumb
ExpansionPanel
Licensing
Rating
ScrollView
ButtonGroup
CheckBoxGroup
NavBar
ProgressBar
QRCode
RadioButton
Scroller
Timeline
TreeMap
TaskBoard
OrgChart
Captcha
ActionSheet
Signature
DateTimePicker
AppBar
BottomNavigation
Card
FloatingActionButton
Localization
MultiViewCalendar
PopOver (Mobile)
Ripple
ScrollView (Mobile)
Switch (Mobile)
PivotGridV2
FlatColorPicker
ColorPalette
DropDownButton
AIPrompt
PropertyGrid
ActionSheet (Mobile)
BulletGraph
Button (Mobile)
Collapsible
Loader
CircularGauge
SkeletonContainer
Popover
HeatMap
Avatar
ColorGradient
CircularProgressBar
SplitButton
StackLayout
TimeDurationPicker
Chip
ChipList
DockManager
ToggleButton
Sankey
OTPInput
ChartWizard
SpeechToTextButton
InlineAIPrompt
TimePicker
StockChart
RadialGauge
ContextMenu
ArcGauge
AICodingAssistant
+? more
Top users last month
Cynthia
Top achievements
Rank 1
Iron
Toby
Top achievements
Rank 3
Iron
Iron
Iron
Danielle
Top achievements
Rank 1
Iron
Iron
Joel
Top achievements
Rank 3
Bronze
Bronze
Iron
yw
Top achievements
Rank 2
Iron
Iron
Iron
Want to show your ninja superpower to fellow developers?
Top users last month
Cynthia
Top achievements
Rank 1
Iron
Toby
Top achievements
Rank 3
Iron
Iron
Iron
Danielle
Top achievements
Rank 1
Iron
Iron
Joel
Top achievements
Rank 3
Bronze
Bronze
Iron
yw
Top achievements
Rank 2
Iron
Iron
Iron
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?