Question

I have an annoying problem with TabActivity. I have several activities in it and when I switch between them each of them gets recreated and loses all its info :(

I've tried using android:launchMode="singleTop" but no luck :(

Any clues?

Was it helpful?

Solution

Here is a sample project showing the use of activities in tabs that does not suffer from the problem you cite.

Even better would be to get rid of the activities and just use views as the contents of your tabs, as that will save RAM, CPU, and battery life. See this project for a sample.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top