[solved]sort 2 tablewidgets simultaneously
-
I have 2 tablewidgets in form. I clicked column of first tablewidget and it was sorted. I want that second tablewidget was sorted wit same order. For example:
first tablewidget
ee
cc
bb
aa
dd
ffand second tablewidget
1
2
3
4
5
6When I click column of first tablewidget, it becomes
aa
bb
cc
dd
ee
ffis it possible to second tablewidget is sorted automcatically like
4
3
2
5
1
6Thanks
-
Hi,
To be sure: QTableView or QTableWidget ?
-
QTableWidget
-
Then AFAIK, you will have to do it manually.
It might be simpler to use 2 QTableViews with a common QAstractTableModel containing all the data
-
Thanks to you and this topic I solved my problem