New to Telerik UI for Blazor? Download free 30-day trial

Batch Editing in the Grid


How to edit several records in the grid at once and to only create one request to the database/service to save the changes? How to implement batch editing?


An example is available in the following project:

Clicking on the "Save All" button while there is an open cell editor can cause a race condition with the browser events. As a result, the new value in the open cell editor may not be persisted. There are two ways to avoid this:

  • Use the OnEdit and OnUpdate events to enable the "Save All" button when the Grid is not in edit mode
  • Check the Grid State in the "Save All" click handler to see if the Grid is in edit mode. In this case, call the OnUpdate handler manually and apply the user changes to the Grid data. Unlike the linked example, there is no need to exit edit mode programmatically, because the Grid will do that. However, mind the possibility for the OnUpdate handler to execute twice.
In this article