Start Building Professional
Web Apps Today


 
Categories Question details Back To List
Question  posted by Tejas Shah on Sep 11, 2008 03:44
open dhtmlx forum
DHX Grid : Design Issues in Grid

Hi there,
There is some design issues in grid as you can see in the link.
It is selecting multiple rows at a time and I haven't selected multiple rows also by Shift or Ctrl key also.
Image Link : http://img204.imageshack.us/my.php?image=designerroringridni0.jpg

It happens after inserting row. I also tried clearSelection() method, but of no use.
Following is the code :

var addRowValues = new Array();
     addRowValues[0] = libTableGrid.getRowIndex(parseInt(libTableGrid.getSelectedId()));
                                     
libTableGrid.addRow(libTableGrid.getSelectedId(),addRowValues,libTableGrid.getSelectedId()-1);
     libTableGrid.clearSelection();
    
     for (var i=0; i<libTableGrid.getRowsNum(); i++)
        {
                var j = i+1;
                libTableGrid.cells2(i,0).setValue(j);
                //libTableGrid.setRowId(i,j);
        }
    
Please Help !!
Answer posted by Support on Sep 11, 2008 04:56
Are you using grid in normal or in split mode?
In second case , there is a known issue which can cause such effect , please contact us directly to receive an update.

>>libTableGrid.addRow(libTableGrid.getSelectedId(),
You creating new row with ID of already existing row, as result you will have non-unique IDs in grid, which may cause issue, same as in your case.