Note that there are some explanatory texts on larger screens.

plurals
  1. POActivity group problem in tab bar
    text
    copied!<p>I have used tabbar with activity group in my application. I have four tab like home, stock, citn, article. In my application first display home page from the home page user click in webview it will go to homepage1 activity. From home page1 activity user click stock tab it will go to stock activity. From the stock activity user click home tab it will go to homepage1 activity. I want to display home activity can any body tell how to do?</p> <p>My question is switching between tab using activity group it will display last activity. I want to display first activity?</p> <p>ok i will attach my code</p> <pre><code>spec = tabHost.newTabSpec("FirstGroup").setIndicator("FirstGroup", getWallpaper()).setContent( new Intent(this,FirstGroup.class)); tabHost.addTab(spec); </code></pre> <blockquote> <p>View view = getLocalActivityManager().startActivity("CitiesActivity", new Intent(this,CitiesActivity.class).addFlags(Intent.FLAG_ACTIVITY_CLEAR_WHEN_TASK_RESET )).getDecorView(); </p> <pre><code> // Replace the view of this ActivityGroup replaceView(view); } public void replaceView(View v) { // Adds the old one to history history.add(v); // Changes this Groups View to the new View. setContentView(v); </code></pre> </blockquote> <p>run this example <a href="http://united-coders.com/nico-heid/use-android-activitygroup-within-tabhost-to-show-different-activity" rel="nofollow">http://united-coders.com/nico-heid/use-android-activitygroup-within-tabhost-to-show-different-activity</a></p> <p>switching between activity and tab </p> <p>I have posted in pastebin, my link is <a href="http://pastebin.com/1zG0HJgv" rel="nofollow">http://pastebin.com/1zG0HJgv</a></p>
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload