context menu for grid


Is there any function showcontextmenu which will open the context menu for selected row in the grid.


Unfortunately there is no such method, but you can use

and calculate x and y as
var pos = grid.getPosition(grid.cells(i,j).cell)
x = pos[0];
y = pos[1];

I am using v.1.6 build 80603 of dhtmlxgrid.js and when I try to use menu.showContextGrid I receive error that its not a function.

Is menu.showContextGrid(x,y) part of higher version?

If yes then can you tell me how can I get this code in my existing version (Note: I also have v.2.0 build 81009 of dhtmlxgrid.js

 ) It would be great if I can just get the necesssary code from the higher version.

showContextMenu (not showContextGrid) is the method of the dhtmlxmenu 2.0 (suite 81009 and higher). The sample is … ntext.html

Grid PRO 81009 supports the latest menu version.

In case of using old menu (v1.0) you can use openAt(x,y) method.