DHTMLX Docs & Samples Explorer

Index
dhtmlxgrid
Event Handling

## onBeforeCMove/onAfterCMove Events

Required library edition:

onBeforeCMove event occurs when column moving operation starts;
onAfterCMove event occurs after a column was moved.

These events pass the following parameters:

- cInd - index of the moved column;
- posInd - index of the new position.

            grid.attachEvent("onBeforeCMove", function(cInd,posInd){});
            grid.attachEvent("onAfterCMove", function(cInd,posInd){});