If variable o is bound to your object, then this will do the trick:
        o.foo

To update it:
        o.foo = newvalue;

Anecdotal evidence suggests that you cannot assign new dynamic properties to 
your object from QML.

Jamey

On Sep 14, 2010, at 11:16 AM, ext [email protected] wrote:

> Hi,
> 
> Is there a way to access dynamic properties from QML? I have a c++ object 
> that does _not_ have a Q_PROPERTY(int foo READ foo), and in c++ I set the 
> value using the setProperty("foo", 42) function call - i.e. a dynamic 
> property.
> 
> Is there a way to access it from QML? I assume that by default declarative 
> doesn't bother to access then for performance reasons, but is there a way to 
> enforce it and ask for the value of such property?
> 
> Denis.
> 
> 
> _______________________________________________
> Qt-qml mailing list
> [email protected]
> http://lists.trolltech.com/mailman/listinfo/qt-qml


_______________________________________________
Qt-qml mailing list
[email protected]
http://lists.trolltech.com/mailman/listinfo/qt-qml

Reply via email to