I want to write an application that can access a table in the database. I took QSqlTableModel as model component for the table.
The problem with the QTableView is that it seems to have no method that returns the currently selected record in the table so i took the QTableWidget class which interhits QTableView.
But when i try to set the model to this table widget with ->setModel() i get the following error message:
c:/Qt/qt/include/QtGui/../../src/gui/itemviews/qtablewidget.h:337: error: `virtual void QTableWidget::setModel(QAbstractItemModel*)' is private.
The message says that the method "setModel" is private. Looking into the documentation tells me that it is public.
What can I do?