Introduction: JavaScript Code to add row to a
GridView.
Code:
<script type="text/javascript" lang="ja">
function AddNewRecord() {
var grd = document.getElementById('<%=gvportfolio.ClientID%>');
var tbod = grd.rows[0].parentNode;
var newRow = grd.rows[grd.rows.length - 1].cloneNode(true);
tbod.appendChild(newRow);
}
</script>