05-04-2011 03:41 PM
Hi everyone!
An app I am working on is almost complete, however there is some fine tuning involved and I've run into a slight problem with one of the issues. I have a progress indicator that shows up while lists are being populated with items. Items populating the lists are dynamic and I am making a service call to get these items. In some cases there are quite a few items within the list and loading them takes a while. The list stays blanks while these items are being populated.
Now the problem is that the progress indicator goes away as soon as the list component is loaded in the view, even though it hasn't finished populating with list items. I want it to work so that the indicator only goes away once all items have been filled within the list. Is there any way I can achieve this or check for this using an event?
Any help or guidance is appreciated.
Thanks!
05-04-2011 04:10 PM - edited 05-04-2011 04:15 PM
the way I populate my lists is by doing an HTTPRequest to an array, have the array as a dataprovider, then remove/add the list that has already been added with the new dataprovider....
so basically, when the app is first loaded, I addchild the list with whatever content i have for it, then when I Hit the button to call the HTTPRequest, I take that data, throw it in an array, and then remove the original list and add the new one.
**And I use an Activity indicator as well for this....I start the activity indicator when the app first loads it data, then end it as soon as the list has been added (which is of course after the data has been populated into the array and used as a dataprovider), and start it whenever the button is pressed again...and end when done and so on...
05-04-2011 04:21 PM
Hmm that is a nice way to do it....I think this might help me and will be a good work around.
Thanks so much!