Answers for "how to delete data from datatables and refresh the table"

C#
1

c# remove rows from datatable

for(int i = dtPerson.Rows.Count-1; i >= 0; i--)
{
    DataRow dr = dtPerson.Rows[i];
    if (dr["name"] == "Joe")
        dr.Delete();
}
dtPerson.AcceptChanges();
Posted by: Guest on August-25-2020
1

Reload datatable

Javascript12345var table = $('#example').DataTable(); table.ajax.reload( function ( json ) {    $('#myInput').val( json.lastInput );} );
Posted by: Guest on August-26-2021

Code answers related to "how to delete data from datatables and refresh the table"

C# Answers by Framework

Browse Popular Code Answers by Language