Deleting Multipls Rows
By default you can delete one row at a time by
returnVal = myData2.splice(index,1);
obj2.refresh();
here the index is the selected row's index in the grid
If you want to delete multiple rows from a grid, you can do this by,
passing the array of indices of the rows.
For example if you want to delete rows having indices 1,3,5,7
all u need to do is , put them in an array and pass it as a parameter.
say tmpary = ["1","3","5","7"], and its length is 4.
so doing as follows will delete first row, third row, fifth row and seventh.
returnVal = myData2.splice(tmpary,tmpary.length);
obj2.refresh();
Kumar S
www.guyfromchennai.com
returnVal = myData2.splice(index,1);
obj2.refresh();
here the index is the selected row's index in the grid
If you want to delete multiple rows from a grid, you can do this by,
passing the array of indices of the rows.
For example if you want to delete rows having indices 1,3,5,7
all u need to do is , put them in an array and pass it as a parameter.
say tmpary = ["1","3","5","7"], and its length is 4.
so doing as follows will delete first row, third row, fifth row and seventh.
returnVal = myData2.splice(tmpary,tmpary.length);
obj2.refresh();
Kumar S
www.guyfromchennai.com
Kumar S
May 18,