Start Building Professional
Web Apps Today


 
Categories Question details Back To List
Question  posted by Rasmit on Jun 18, 2009 02:25
open dhtmlx forum
How to set focus to a cell with edit mode ?

Hi,
I want to made a cell (ex: 8th cell of rowId-1) editable and also keep focus on that cell.
Could you help me, how to do this?

I tried with,
mygrid.selectCell(2, 8);
mygrid.editCell();

But not working.

thanks,
Rasmit.
Answer posted by dhxSupport on Jun 18, 2009 02:48
If you are calling that methods by clicking on some button you shuld cancel bubble for the "onclick" event:
 <button onclick="(arguments[0]||window.event).cancelBubble=true;mygrid.selectCell(2,8,false,false,true)">select cell</button>

*5th parameter of the selectCell() method could be used to switch cell to the edit mode