Thank you for visiting the BlackBerry Support Community Forums.
- Kevin Michaluk, Founder, CrackBerry.com
01-14-2014 05:09 AM
I wanted a datamodel object globally across the qml pages.
I querried from sqlite and result stored in datamodel . this same datamodel values i wanted to access from page 3 , page 4 etc. (how to make that datamodel object available globally)
01-14-2014 05:25 AM
01-14-2014 06:34 AM
What Simon is saying is that you could create your dataModel in the main.qml, if you then give it an id it should be accessible from any qml file after that by referencing that id.
So if you are using a navigationPane for instance you could reference it by;
in every page you push on to the stack.
Alternatively you can use a Qt global variable
Qt.dm = <dataModelId>
01-14-2014 07:49 AM