Hi Johannes, Thanks for your valuable suggestion, it worked fine in most of the cases where i was setting text values from model data. But I still have same issue with "model" property in QML ListView. I tried setting model value as suggested by you: model: myModel ? myModel : ""
But its still giving me warning which says "ReferenceError: Can't find variable: myModel" I'm getting the data but want to get rid of this warning; is there any way i can do it?? On Tue, Mar 13, 2012 at 10:38 AM, manoj jangra <g4m...@gmail.com> wrote: > Thanks, it worked.. :) > > > On Mon, Mar 12, 2012 at 5:05 PM, Johannes Zellner < > johannes.zell...@nokia.com> wrote: > >> Hi Manoj, >> >> On 03/12/2012 11:27 AM, ext manoj jangra wrote: >> > Hello All, >> > I'm getting warnings (Unable to assign [undefined] to QString text) >> > while trying to load data into a gridmenu in QML from C++ files. >> > In QML file I load this data by declaring source as >> > "source:model.image". and set the model data from C++ file. >> > Data is loaded successfully but I'm getting warnings as mentioned above. >> > Can anyone please help me out in getting rid of these warnings?? >> You might want to check in the binding if the string value you try to >> assign is valid. >> eg. >> >> Text { >> text: myValue ? myValue : "" >> } >> >> >> Regards, >> >> Johannes >> >> _______________________________________________ >> Qt-qml mailing list >> Qt-qml@qt.nokia.com >> http://lists.qt.nokia.com/mailman/listinfo/qt-qml >> > > > > -- > WIth Best Regards > Manoj > > Save a Paper; Save a Tree.... > -- WIth Best Regards Manoj Save a Paper; Save a Tree....
_______________________________________________ Qt-qml mailing list Qt-qml@qt.nokia.com http://lists.qt.nokia.com/mailman/listinfo/qt-qml