How can I disable right click/context menu for ag-grid?

Pratik N picture Pratik N · Dec 10, 2018 · Viewed 7.7k times · Source

I am using ag-grid enterprise version and I want to disable context menu or a right click on the grid cells but I did not found any solution.

Here is my code

<ag-grid-angular #agGrid style="width: 100%; height: 100%;" id="myGrid" 
[rowData]="rowData" class="ag-theme-balham" [columnDefs]="columnDefs" 
[enableRangeSelection]="true" (gridReady)="onGridReady($event)"></ag-grid- 
angular>

enter image description here

Answer

LazyDeveloper picture LazyDeveloper · Dec 10, 2018
suppressContextMenu:true for gridOptions

Will work