onColumnResize

fires when the user is dragging the column's border to resize the column

void onColumnResize(number index,object column,number new_width);
indexnumberthe column index
columnobjectthe column object
new_widthnumberthe new column's width

Available only in PRO Edition

Example

gantt.attachEvent("onColumnResize", function(index, column, new_width){
    if(!message){
        message = gantt.message({expire:-1,
        text:`<b>${gantt.locale.labels["column_"+column.name]}
        </b> is now <b id='width_placeholder'></b><b>px</b> width`});
    }
    document.getElementById("width_placeholder").innerText = new_width
});

Related samples

Details

This functionality is available in the PRO edition only.

See also
Back to top