[SOLVED]Current record from QSqlQueryModel
-
How can I get current QSqlRecord from QSqlQueryModel?
P.S. I attached QSqlQueryModel to QTableView
-
HI mbnoimi.
Maybe it's not that you need, but did you see "QSqlQueryModel::record(int row)":http://qt-project.org/doc/qt-5.0/qtsql/qsqlquerymodel.html#recordRegards.
-
[quote author="SergioDanielG" date="1373664056"]Maybe it's not that you need, but did you see "QSqlQueryModel::record(int row)":http://qt-project.org/doc/qt-5.0/qtsql/qsqlquerymodel.html#record[/quote]
Sure it doesn't work because current row is unknown!
-
What about:
@QSqlQueryModel::record(QTableView::currentIndex().row())@ -
[quote author="qxoz" date="1373972086"]What about:
@QSqlQueryModel::record(QTableView::currentIndex().row())@[/quote]Thanks I found out the solution but I forgot to update the thread.