I am looking to create an Android application that uses Tabs.
Requirements
When a user selects a tab and gets back to the same tab, there shouldn’t be a loading period (preferably).
Each tab will contain a listview.
In one of the tabs, I will have to use subtabs.
And that’s it.
One great example I really liked (although I didn’t try the app) is http://www.usatoday.com/android/.
I just developed a tabbed application and I used the following function to create tabs in code. The function uses intents which mean when ever a tab is selected an Activity is loaded in the tab body using intent. This function is called in main activity.
The list view in NewsList Activity is made by XML as following:
In Response to Fabios’ comment below:
Yes wither use visibility property or try implementing tabs using the way mentioned below:
Where as Layout file is as below: