Grid Destory command passing null to controller

0 Answers 63 Views
Top achievements
Rank 1
Guest10 asked on 12 Jul 2023, 01:39 AM

My Grid has the following code


.DataSource(dataSource => dataSource
                            .Model(model => model.Id(p => p.No))
                            .Destroy(update => update.Action("DeleteData", "DataController"))
                            .Events(evt => evt.Error("cancelDelete"))


Following is the controller

        public ActionResult DeleteData([DataSourceRequest] DataSourceRequest request, Datamodel data)


I see data has null when it call the controller function


What could be the reason for data is null and the No is not passed.




Anton Mironov
Telerik team
commented on 14 Jul 2023, 01:33 PM

Hi Chakrapani,

Thank you for the code snippets and details provided.

The fastest route to getting you up and running is if you could provide a runnable, isolated, sample project. Examining this project will let us replicate the issue locally and further troubleshoot it.

Looking forward to hearing back from you.

Kind Regards,
Anton Mironov

No answers yet. Maybe you can help?

Asked by
Top achievements
Rank 1
Share this question