Start TabActivity from ListActivity (which is content of parent TabActivity) in Android

Posted by barmaleikin on Stack Overflow See other posts from Stack Overflow or by barmaleikin
Published on 2010-05-20T17:07:50Z Indexed on 2010/05/20 17:10 UTC
Read the original article Hit count: 900

Filed under:
|

Hi guys,

I have problems with switching between activities.

I have two TabActivities (A and B), each of of tab activity has 4 tabs with ListActivity. I am trying to show B activity onListItemClick.

Code on click is:

Intent intent = new Intent(getApplicationContext(), TabBActivity.class);
startActivity(intent);

My manifest file is following:

<manifest xmlns:android="http://schemas.android.com/apk/res/android"
      package="com"
      android:versionCode="1"
      android:versionName="1.0">
    <application android:icon="@drawable/app_icon" android:label="@string/app_name" android:debuggable="true">
     <activity android:name=".SplashScreen"
                  android:label="@string/app_name">
            <intent-filter>
                <action android:name="android.intent.action.MAIN" />
                <category android:name="android.intent.category.LAUNCHER" />
            </intent-filter>
        </activity>
        <activity android:name=".TabAActivity">
            <intent-filter>
                <action android:name="com.TabAActivity" />
                <category android:name="android.intent.category.LAUNCHER" />
            </intent-filter>
        </activity>

        <activity android:name=".TabAListActivityA" android:label="AA"/>
        <activity android:name=".TabAListActivityB" android:label="AB"/>
        <activity android:name=".TabAListActivityC" android:label="AC"/>

        <activity android:name=".TabBActivity" android:label="B"/>

        <activity android:name=".TabAListBctivityA" android:label="BA"/>
        <activity android:name=".TabAListBctivityB" android:label="BB"/>
        <activity android:name=".TabAListBctivityC" android:label="BC"/>
    </application>
</manifest>

Is my manifest correct or maybe something is wrong with code? I would appreciate any help on this topic.

© Stack Overflow or respective owner

Related posts about android

Related posts about listactivity