Start Building Professional
Web Apps Today


 
Categories Question details Back To List
Question  posted by Gabriel on Jan 15, 2009 12:00
open dhtmlx forum
subgrid (type=grid) & tab behaviour

The online sample contains the sub_row_grid excell, not subgrid (type=grid) but the behaviour is almost the same (both IE & FF 3.0.5) . The tab key at the end of the sub_row_grid doesn't go to the next row in grid but goes to the browser menu.

In subgrid (cell type=grid) the keymap is not working at all (nor tab , or up/down keys)  (Applies for both IE & FF)

Thanks
Answer posted by Support on Jan 16, 2009 04:13
>>The online sample contains the sub_row_grid excell, not subgrid (type=grid)
actually it has mixed rows, while first is sub_row_ajax, the second and third are sub_row_grid

>>he tab key at the end of the sub_row_grid doesn't go to the next row in grid but goes to the browser menu.
yes, this is known limitation, the sub-grid and master grid only visually placed as single structure, but in fact their tab orders are absolutely different, and not linked.

>>In subgrid (cell type=grid) the keymap is not working at all
"grid" column type was designed as "rich select" which allow to select one of records and was not purposed for edit operations
Answer posted by Gabriel on Jan 16, 2009 04:16
Is it possible to register a onTab event or action for tab key for the subgrid which will focus on the master grid's next tab?
Answer posted by Support on Jan 16, 2009 04:25
mygrid.attachEvent("onSubGridCreated",function(sub,id,ind){
         var master = this;
         sub.attachEvent("onTab",function(){
                  if (this.getRowIndex(this.getSelectedRowId())==this.getRowsNum()-1){
                           master.setActive(true);
                           master.selectCell(master.getRowIndex(id)+1,0);
                  } else return true;
         })
});