copy/paste a row

Hi,
i can copy a row, after the selected row, and in this row i’ve got 3 combos.
In the first combo, when i do the copy, the new combo(in the new row) contains text, and not the id (what i want), and the second and third combo contain the id and not the text(what i want).

I tried lots of differents possibilities but i can’t find the right way to get what i want.

Can you please help me ?

What i do is:
1- insert a new row after the selected row with the selected row values.
i set/get the new values for the new row like this (for the combo):
var insProject = Grid.cells(rowId, cellIndProject).getValue();
var insTask = Grid.cells(rowId, cellIndTask).getValue();
var insActivity = Grid.cells(rowId, cellIndActivity).getValue();
Grid.addRow(insId, insDay + ‘,’ + insDate + ‘,’ + insAdd + ‘,’ + insProject + ‘,’ + insCategory + ‘,’ + insTask + ‘,’ + insActivity + ‘,’ + insEffort + ‘,’ + insRnum + ‘,’ + insTot + ‘,’ + insDelete + ‘,’ + insCopy, ind);

the new row is inserted, but the values are not what i expect.

Thx

To get the value of your combo option try to use getText() method:

Grid.cells(rowId, cellIndProject).getText();

big thx, it’s working…

-> Resolve :slight_smile: