Expand my Community achievements bar.

How to append new rows in a table with Javascript ?

Avatar

Level 2

Hi ,

I'd like to append new rows in a table dynamically using javascript?

Do some of you have already done this before ?

2 Replies

Avatar

Level 4

You can use:

     form1.subform1.tableForm.instanceManager.addInstance(true);

Make sure your subform1 is flowed and that the tableForm as the "Repeat SubForm for Each Data Item" selected.

Avatar

Former Community Member

Rui's answer will create copies of the entire table.  There may be times where thsi is what you want, but you asked about creating new rows.  If your new row is a copy of one of your existing rows, then you could use

_RowName.addInstance(1);

(the underscore at the beginning invokes the instance manager).  Is this what you're looking for?