Welcome to the official BlackBerry Support Community Forums.

This is your resource to discuss support topics with your peers, and learn from each other.

inside custom component

Native Development

Posts: 163
Registered: ‎04-28-2012
My Device: BlackBerry 9800
My Carrier: BlackBerry

QListDataModel sample application?



     Anyone can provide me the sample application for creating a listview using  QListDataModel.I want to create a imagelistview and those images should be downloaded from url.In the qml i have created a listview and using ListItemData property i want to set the image for the list item.I tried with GroupDataModel stored the image in QVariantMap along with other strings i did not save the images in the filesystem.If i store those files in the filesystem then i am able to show those images in the listview .I read in the documentation that this  model will show the items in the listview if it is convertible to QVariant.Please provide me the sample application using QListDataModel.



Naresh Kodumuri/

Posts: 121
Registered: ‎11-19-2008
My Device: Not Specified

Re: QListDataModel sample application?

The bucketlist sample application uses QListDataModel: http://developer.blackberry.com/cascades/sampleapps/

You can also download it from GitHub: https://github.com/blackberry/Cascades-Samples


Posts: 136
Registered: ‎01-25-2010
My Device: Z30, Z10, Q10, Dev Alpha B & Bold 9900
My Carrier: Bell

Re: QListDataModel sample application?

[ Edited ]

To load your image from a URL, you can look @ the following project..


I used it in my projects and it works very nicely, the component is pretty slick Smiley Happy This was taken from the following post...



There is a variant, which I can't recall that uses caching... This will avoid pulling the images each time. If you can garantee the image never changes, this is a great add-on to avoid costly data pull.