Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

Code Block
languagejs
<script>
    $("body").on("page_loaded", function() {
        var hot = FormUtil.getField("sp_grid_data_via_js").data("hot");
        var col = hot.countRows();	
        hot.alter('insert_row_below', col, 1);	

        
        hot.setDataAtCell(col, 0, '-Name-P. Rick');
        hot.setDataAtCell(col, 1, '-Surname-58');
        hot.setDataAtCell(col, 2, '-Age-8');
    });
</script>


Reference: https://jsfiddle.net/ck4859zm/

...