0
votes

We are trying to identify when user clicks on entire ROW instead of cell using office.js in excel addin. I was able to use to an event handler with matrix binding to identify the user click in a cell, but it doesn't work when user clicks on the entire row. Just wondering if anyone of you able to resolve.

Thanks,

1

1 Answers

1
votes

there is no direct way of knowing this, but you can infer it. The selectionChanged eventArgs include useful information to achieve this. Check out the documentation here, specifically the startRow, startColumn, rowCount, columnColumn, those properties are basically the coordinates of what's been selected in your table/range. Also probably you already know this, but the Matrix and Table bindings have a binding.columnCount property that you can use in conjunction the EventArgs described above and doing some simple math you can infer if only one row is selected and if all the columns in that row are selected.

Hope this is not too confusing and useful for your scenario.

thanks!