How to ENABLE the row DELETE confirmation alert "Are you sure you want to delete this record?" when you delete a record from the Grid?
Here is the sample code from the "Examples" folder.
I tried calling editable.DisplayDeleteConfirmation(true);.
But "DisplayDeleteConfirmation" does not work irrespective of true or false.
How to ENABLE the row DELETE confirmation alert?
Thank you.
@(Html.Kendo().Grid<Kendo.Mvc.Examples.Models.ProductViewModel>()
.Name("Grid")
.Columns(columns => {
columns.Bound(p => p.ProductName);
columns.Bound(p => p.UnitPrice).Width(140);
columns.Bound(p => p.UnitsInStock).Width(140);
columns.Bound(p => p.LastSupply).Width(140);
columns.Bound(p => p.Discontinued).Width(100);
columns.Command(command => { command.Edit(); command.Destroy(); }).Width(200);
})
.ToolBar(toolbar => toolbar.Create())
.Editable(editable => { editable.DisplayDeleteConfirmation(true); editable.Mode(GridEditMode.InLine); })
.Pageable()
.Sortable()
.Scrollable()
.DataSource(dataSource => dataSource
.Ajax()
.Events(events => events.Error("error_handler"))
.Model(model => model.Id(p => p.ProductID))
.Create(update => update.Action("EditingInline_Create", "Grid"))
.Read(read => read.Action("EditingInline_Read", "Grid"))
.Update(update => update.Action("EditingInline_Update", "Grid"))
.Destroy(update => update.Action("EditingInline_Destroy", "Grid"))
)
)
18 Answers, 1 is accepted
Thanks.
Indeed, the confirmation option does not function correctly. However, we managed to address this issue and the fix will be available with the next release.
Regards,Rosen
the Telerik team
Can you please also guide me as to where i can find any any documentation for Kendo UI MVC.
Thanks.
The documentation for KendoUI for ASP.Net MVC can be found here.
Regards,Rosen
the Telerik team
The functionality in question is available in the official Q2 2012 version of KendoUI for ASP.Net MVC.
All the best,Rosen
the Telerik team
Also I've found that setting the default value for model field doesn't seem to be working. Do I need a different version? And if so where do I download and install that version?
Unfortunately, both of the features are currently not available when server binding is used. However, we managed to address this behavior and the fix will be available with the next internal build.
Greetings,Rosen
the Telerik team
Any chance to provide an update on this fix using Server Binding? Last build was from July and we are now in September.
Thanks
As I have mentioned the fix is available through the internal builds, which you can download via your account.
Regards,Rosen
the Telerik team
You can set a custom confirmation message through the overload of the Editable's DisplayDeleteConfirmation method.
Regards,Rosen
the Telerik team
Could you please verify that you are using the latest internal build? As this improvement is also added after the official Q2 2012 release of KendoUI. Please excuse me if I have mislead you.
Greetings,Rosen
the Telerik team
Unfortunately, in this case you will need to wait for the next official release of KendoUI which will also contain this enhancement.
All the best,Rosen
the Telerik team
Im kind of stuck here and have been putting in alot of time chasing my tail trying to make things work that dont work as suggested in documentation.
As you may know the internal builds as well as the minor version are only available to our commercial license holders. The next major release will be the Q3 2012 which will be available in mid November.
All the best,Rosen
the Telerik team