Remove row by field value
Remove row by field value
dynasoft
Posts: 439Questions: 68Answers: 3
Hi
I can remove a table row by using the row's index:
table2.row( ':eq(' + j.toString() + ')' ).remove()
The problem is iterating through a table the indices of existing rows change as previous rows get deleted. How can I remove multiplie rows safely?
This discussion has been closed.
Answers
I created this example for another thread. It uses
indexes()
andfilter()
to get a list of indexes of rows matching a condition. Then it will remove the rows.http://live.datatables.net/gimefafe/1/edit
Kevin
Thank you.