ThinkNewDev
ThinkNewDev

Reputation: 668

AsyncTask Question

I have a TabActivity with several lists. I want to use AsyncTask but I am not sure how to implement it to use the same Task to handle multiple lists. Basically the lists are the same just changed by type. Is it flexible enough that I can extend AsyncTask and let it handle a variety of calls?

Thanks!

Upvotes: 2

Views: 1021

Answers (1)

user3404558
user3404558

Reputation:

Why are you using TabActivity with Several lists...That may look awkward if the lists are empty for any tab then it will appear like blank...so instead of that you can use ExpandableListView and ExpandableListActivity...That would certainly achieve your requirements....and if you need you can use AsynTask there too. You can find good exaple tutorial on ExapnadableListView on youtube. you can see the link for sample reference..

http://www.androidhive.info/2013/07/android-expandable-list-view-tutorial/

Upvotes: 1

Related Questions