Quantcast
Channel: Qt DevNet forums: Qt Quick 1283365070**
Viewing all articles
Browse latest Browse all 4972

'QQmlListProperty' is not registered?

$
0
0
I want to use QQmlListProperty to access list-values in QML. The class where I register the list with     Q_PROPERTY(QQmlListProperty<int> items READ items) is a singleton class. I register it with     qmlRegisterSingletonType<Appointment::MVC::ApModel>("appointment.model.apmodel",1,0,"ApModel",Appointment::MVC::apModelSingletonTypeProvider); in my main.cpp. The usage of other properties works fine, but when I want to access the list, QML prints out the following error: QMetaProperty::read: Unable to handle unregistered datatype ‘QQmlListProperty<int>’ for property ‘Appointment::MVC::ApModel::items’ Did I forget something?

Viewing all articles
Browse latest Browse all 4972

Latest Images

Trending Articles



Latest Images