[Solved]QModelIndex get data
-
Hi all
I have a QListView with its model set with QSqlQueryModel object.
The QSqlQueryModel contains a table with two columns (id and name), the QListView is set to show the name
I have connected the QListView with the signal clicked(), the slot receives a QModelIndex object. How do I get the id from the QSqlQueryModel from the QModelIndex ?
Thanks
DarkRoast