Answer the question
In order to leave comments, you need to log in
How to correctly delete the last row of a table?
Hi all.
The question is, I have an HTML table where I delete rows with this function:
function DeleteRow(rowNo) {
document.getElementById("Table").deleteRow(rowNo);
}
Answer the question
In order to leave comments, you need to log in
Understood. I deleted the line through my context menu, which was called by clicking on the desired line. And there is a function that keeps track of the line I click on and highlights it with color through styles. After that, I click on another line, the selection on the previous line is removed through styles. And when the previous line is removed, this error occurs. The function cannot find the styles of the removed element.
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question