Categories | Question details Back To List | ||||||||
DhtmlxGrid I am using the following code to add a new row into the grid on f-12 key. But instead on inserting the new row just above the selected row, a new row is being inserted at the top of the grid. Why is this happening? mygrid.attachEvent("onKeyPress",function(code){ if (code == 123 ){ mygrid.addRow((mygrid.getRowsNum()+1),['','','','','','','','','','','','','','','','','',''],mygrid.getRowIndex(mygrid.getSelectedId())); } else return true;}); Answer posted by Support on May 08, 2008 02:50 The same code works fine in case of local samples ( please check attached sample ) Most probably issue caused by usage on non-unique IDs in grid ( please be sure that each row in grid has unique ID ) Attachments (1)
|