Welcome!

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

Adobe AIR Development

Reply
Highlighted
Contributor
Posts: 42
Registered: ‎08-30-2012
My Device: PlayBook
My Carrier: Aircel
Accepted Solution

Loading data into list when needed

HI to everyone,

 

I am Displaying Huge Data from Database in list,

I dont want to load the entire data in a single shot, i want to show it as loaded means (if user scroll the list it automatically loads the data from my db?)

any ideas? 

 

Thank you,

Developer
Posts: 251
Registered: ‎11-22-2011
My Device: Blackberry Playbook
My Carrier: vodafone

Re: Loading data into list when needed

I think it depends on the type data.

 

When you have a few hundred datasets with text only, i think its not a problem to load the complete result in a dataprovider. The list control itself runs fine even with very huge lists, because it reuses and fill the lines on the fly.

 

How big is your database?

 

Developer
Posts: 6,541
Registered: ‎10-27-2010
My Device: HTC One, PlayBook, LE Z10, DE Q10
My Carrier: Verizon

Re: Loading data into list when needed

You will need to "page" your requests (offset + length). You can do this as the person scrolls or add a button at the bottom of the list with "More..." to load more data. And unload at the top if you are too "far" from it.
Contributor
Posts: 42
Registered: ‎08-30-2012
My Device: PlayBook
My Carrier: Aircel

Re: Loading data into list when needed

I have more than 20,000 records in my database,

ther is no problem with retrival of data, I want to give feasabilty t0 user, that he can able view the loading of data into list,

 

eg:

i am using section list to display data there is around 30 header section in each section 1000 recoeds are presented,

if he scroll the list he can able to see the loading data.

 

Contributor
Posts: 42
Registered: ‎08-30-2012
My Device: PlayBook
My Carrier: Aircel

Re: Loading data into list when needed

Hi Sir,
It seems to work explain me with example

Thank you
Developer
Posts: 6,541
Registered: ‎10-27-2010
My Device: HTC One, PlayBook, LE Z10, DE Q10
My Carrier: Verizon

Re: Loading data into list when needed

You'll need to verify if sqlite supports offsets and limits.

http://www.sql.org/sql-database/postgresql/manual/queries-limit.html