#103339

Hi Rafa,

You can add an event listener to Grid cells like that:

const grid = document.querySelector('smart-grid');
grid.addEventListener('cellClick', function (event) {
    const detail = event.detail,
        cell = detail.cell,
        originalEvent = detail.originalEvent,
        id = detail.id,
        dataField = detail.dataField,
        isRightClick = detail.isRightClick,
        pageX = detail.pageX,
        pageY = detail.pageY;

	// event handling code goes here.
})

The data field is the column’s data field and you will be able to identify the column by using that event.

Best regards,
Jack

Smart UI Team
https://www.htmlelements.com/