Currently, I am utilizing ag-grid for my project. Within my gridOptions
, there are event handlers defined as follows:
gridOptions =
{
...
onCellEditingStarted: function (event) { /* magic happens!*/ },
onCellEditingStopped: function (event) { /* magic happens!*/ }
...
}
Everything operates smoothly when cell editing starts or stops. However, I have encountered a situation where I need to trigger these events from another .js file that does not possess an ag-grid instance.
I have attempted the following approach:
$(window).trigger('cellEditingStopped');
Regrettably, this method is unsuccessful. What mistake am I making? Is it feasible to trigger ag-grid events in this manner, or do I require additional code?