Hi,
Is is possible to have multiple modl attched to single view.
If yes,Please suggest how?
Thanks
Hi,
Is is possible to have multiple modl attched to single view.
If yes,Please suggest how?
Thanks
Yes. Use QAbstractItemView::setModel() multiple times with different views and same model.
I suspect the OP means "at the same time". That is, the single view is showing some data from model A, and some from model B at the same time.
The general answer would be no in this case (at least with respect to the standard views supplied). If the two models were of two related tables in a database then the QSqlRelationalTableModel is a good place to look for alternative approaches.
Thanks for your reply
Bookmarks