title: how to select second tab bar when start
body: <p>how to go 2nd tab bar when click ? is select always 1st tab bar I want to select 2nd tab bar when screen show tab bar my screen select 1st tab bar </p>
  
  <p><a href="https://i.stack.imgur.com/0ek03.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/0ek03.png" alt="image"></a></p>
  
  <p>I want to select 2nd tab bar when starting like this  </p>
  
  <p><a href="https://i.stack.imgur.com/VjoK9.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/VjoK9.png" alt="image2"></a></p>
  
  <p>my code is below </p>
  
  <pre><code>public class TabBarActivity extends TabActivity {
  /** Called when the activity is first created. */
  
      public void onCreate(Bundle savedInstanceState) {
          super.onCreate(savedInstanceState);
          setContentView(R.layout.main2);
          setTabs() ;
      }
  
      private void setTabs()
      {
          addTab("payments", R.drawable.tab_home, AgAppPaymentScreen.class);
          addTab("My Account", R.drawable.tab_home, AgAppMyAccountScreen.class);
  
          addTab("Spend Analyzer", R.drawable.tab_home, AgAppPaymentScreen.class);
          addTab("Notification", R.drawable.tab_home, AgAppPaymentScreen.class);
          addTab("Help", R.drawable.tab_home, AgAppPaymentScreen.class);
      }
  
      private void addTab(String labelId, int drawableId, Class&lt;?&gt; c)
      {
          TabHost tabHost = getTabHost();
          Intent intent = new Intent(this, c);
          TabHost.TabSpec spec = tabHost.newTabSpec("tab" + labelId); 
  
          View tabIndicator = LayoutInflater.from(this).inflate(
              R.layout.tab_indicator, getTabWidget(), false);
          TextView title = (TextView) tabIndicator.findViewById(R.id.title);
          title.setText(labelId);
          ImageView icon = (ImageView) tabIndicator.findViewById(R.id.icon);
          icon.setImageResource(drawableId);
  
          spec.setIndicator(tabIndicator);
          spec.setContent(intent);
          tabHost.addTab(spec);
      }
  }
  </code></pre>