Hi Sayali,
Thanks for contacting Syncfusion support.
Query #1: How can i do batch delete in Data Grid?
We suggest you to set edit mode as “Batch” in Grid editSettings property to perform the batch add, batch delete and batch update action in Grid. You can set the edit mode as “Batch” like as below code snippet,
editSettings: { allowEditing: true, allowAdding: true, allowDeleting: true, mode: "Batch" } |
We have already discussed about this topic in our help documentation. So please refer the below documentation link to know more details about Grid batch editing,
Query #2: Also how can i select multiple rows in data grid
We suggest to set type as “Multiple” in Grid selectionSettings property to enable the multiselect option. You need use “Ctrl + mouse left click” to perform the multi selection in Grid.
selectionOptions: { type: "Multiple" } |
Query #3: get id's of all those selected rows?
We suggest to use the Grid getSelectedRecords method to get the selected records details. Please refer the below code snippet,
btnClick: e => {
var grid = document.getElementById("Grid").ej2_instances[0];
var selectedRecords = grid.getSelectedRecords();
alert(JSON.stringify(selectedRecords));
} |
Also, we would like to inform that getSelectedRows and getSelectedRowIndexes methods of the Grid. This methods are used to find the selected row elements and find the selected row indexes. Please refer the below documentation links to know more details about this methods,
We have prepared the sample this requirement and you can find that sample from the below link for further assistance,
Regards,
Hariharan