I need a way to only allow the user to select a row or a column (or multiple selection of entire rows, and entire columns) using handsontable.
Restricting selection to entire row/column in handsontable
2.6k views Asked by Diego Pamio At
3
There are 3 answers
0
On
After a bit of research and experimentation, I was able to achieve single-row highlighting without the cell and row handles.
Handsontable options:
var x = new Handsontable(element, {
...
multiSelect: false,
disableVisualSelection: ['current', 'area'],
currentRowClassName: 'currentRow'
}
CSS:
.currentRow, .highlight {
background-color: lightblue;
}
0
On
There is an way to select multiple cells, range cells and even single cell by setting: selectionMode='multiple'
checkout this link: https://docs.handsontable.com/pro/3.0.0/Options.html#selectionMode
I ended up with this solution:
works like charm!