PDA

View Full Version : Map QSqlTableModel Column 2 To QListView



donmorr
31st August 2010, 20:44
Hi All,
I'm trying to map the second column of data from a QSqlTableModel to a QListView. How would I go about doing this?
By default it displays the first column of data from the model in the QListView.
Cheers,
Donal

armonge
31st August 2010, 21:20
Try using QListView::setModelColumn(int column)

donmorr
1st September 2010, 12:50
Great, thank you!

wxwok
27th November 2023, 14:49
Try using QListView::setModelColumn(int column)

It really works, Thank you very much.