Hi kalum,
Thanks for contacting Syncfusion support.
You can get the cell value from the row index and column index by
using the “getCellFromIndex” method. If you have only the column field value,
then you can get the index by using the “getColumnByField” method. Please refer
to the below code example and the API link for more information.
document.getElementById('getValue').addEventListener('click', (e) => {
var colIndex = grid.getColumnByField('CustomerName').index; // to get the column index
console.log(grid.getCellFromIndex(1, colIndex).innerText); // this will return the cell value from the second row since the
row index starts from 0
});
|
API : https://ej2.syncfusion.com/documentation/api/grid/#getcellfromindex
https://ej2.syncfusion.com/documentation/api/grid/#getcolumnbyfield
Regards,
Pavithra S
If this post is helpful, please consider Accepting it as the
solution so that other members can locate it more quickly.