How do I trigger a “ondblClickRow” event in jqGrid? I need to invoke the double click event handler of the row on a click of a button.
button:
<a class="btn" id="shwDetails" type="button>Details</a>
grid:
$("#gridX").jqgrid({
...
...
ondblClickRow : function(rowID, iRow, iCol, e){
// event handler
fetchRowData(rowID);
}
...
...
});
The following doesn’t seem to be working.
$('#gridX').trigger( 'jqGridDblClickRow' );
$('#gridX').trigger( 'ondblClickRow' );
Thanks in advance.
I your special case you can just call the function
fetchRowDatadirectly instead of “trigger aondblClickRowevent”.If some other code create jqGrid and you really need to “trigger” callback function
ondblClickRow(not an event) you can do the following: