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

GridEditMode.PopUp error. GridEditMode.InCell works fine

1 Answer 151 Views
Grid
This is a migrated thread and some comments may be shown as answers.
Andrey
Top achievements
Rank 1
Veteran
Andrey asked on 01 Jun 2018, 07:29 PM

Hi,

I run the demo from https://demos.telerik.com/aspnet-mvc/grid/editing-popup and having error: System.ArgumentException: 'Value cannot be null or empty.
Parameter name: name. It was during the first initial (controller not hit). MVC 5 application.

If I change GridEditMode.PopUp to GridEditMode.InCell or InLine then Grid works fine. Is it some setup problem? Is there any scripnt needs to be included in bundle in case of GridEditMode.PopUp?

Here is the Grid code:

@(Html.Kendo().Grid<OnTargetInv.Models.EmailAddress>()
.Name("GridEmails")
.Columns(columns =>
{
columns.Bound(p => p.Email);
columns.Bound(p => p.EmailAddressID).Width(140).Hidden();
//columns.Bound(p => p.InactiveDate).Width(140);
columns.Command(command => command.Destroy()).Width(150);
})
.ToolBar(toolbar => toolbar.Create())
.Editable(editable => editable.Mode(GridEditMode.PopUp))
.Pageable()
.Sortable()
.Scrollable()
.HtmlAttributes(new { style = "height:550px;" })
.DataSource(dataSource => dataSource
.Ajax()
.PageSize(20)
.Events(events => events.Error("error_handler"))
.Model(model => model.Id(p => p.EmailAddressID))
.Create(update => update.Action("EditingPopup_Create", "Client"))
.Read(read => read.Action("EditingPopup_Read", "Client"))
.Update(update => update.Action("EditingPopup_Update", "Client"))
.Destroy(update => update.Action("EditingPopup_Destroy", "Client"))
)
)

Thanks.

1 Answer, 1 is accepted

Sort by
0
Accepted
Georgi
Telerik team
answered on 05 Jun 2018, 11:37 AM
Hello Andrey,

The editing functionality of the grid depends on the Kendo Window

Could you please make sure that the scripts of the Kendo Window are included within the page?

Furthermore, I would recommend you to take a look at our custom script download as it allows you to create a custom script depending on which widgets are used:


In case all necessary scripts are included and the issue still occurs. Sharing a demo that clearly replicates the issue would definitely help us fully understand the case and we will be able to provide further assistance to the best of our knowledge.


Regards,
Georgi
Progress Telerik
Try our brand new, jQuery-free Angular components built from ground-up which deliver the business app essential building blocks - a grid component, data visualization (charts) and form elements.
Tags
Grid
Asked by
Andrey
Top achievements
Rank 1
Veteran
Answers by
Georgi
Telerik team
Share this question
or