How to get data from SQLite to bidding tableview (QML)
Unsolved
QML and Qt Quick
-
wrote on 27 Oct 2015, 07:25 last edited by
Hi,
I need to bindding data from SQLite to TableView using QML.
Currently, I using ListModel for make suorce Tableview.
But, i don't know, how to get data from database and mapping with ListModel (each ListElement of ListModel).
Can you help me solve this problem.
Thanks -
wrote on 27 Oct 2015, 08:11 last edited by
Maybe this helps: QML and QSqlTableModel
-
wrote on 27 Oct 2015, 08:38 last edited by
Thanks hpollak!
When i see topic https://forum.qt.io/topic/59909/binding-list-from-c-to-qml
I do not understand how it's running?
I have a List object in cpp file, and i want binding to gridview on qml file. Which supports updating data when i change value on a item selected?Thanks,
Tuan -
wrote on 28 Oct 2015, 06:28 last edited by
The TableView gets the data by the data(.....) - Methode to indicate the data is changed, the dataChanged(..) signal should be emitted.
4/4