PDA

View Full Version : Qt 5.13 QTableWidget How to select/deselect all rows



ad5xj
14th November 2019, 14:26
I have a project using the QTableWidget as the data display.

My question / issue is how to select all rows without iterating through each to select one at a time. Deselect of all rows is the same problem.

Is there a way to do this efficiently or must i code it into a loop moving through each row one at a time to select or deselect?

Any help is appreciated.

Ginsengelf
15th November 2019, 09:05
Hi, QTableWidget::setRangeSelected() looks like it does what you want.

Ginsengelf