【发布时间】:2014-01-20 10:00:43
【问题描述】:
我知道这个问题经常遇到并且有很多帖子。但是,在阅读并尝试每个答案后,我仍然遇到问题。 我的三星 Galaxy Note 10.1 没有问题,但问题出现在我的三星 Galaxy ACE 手机 FROYO 2.2.1 上,即使我从 google play testing 下载了相同的 apk。
在启动时,我立即收到一条警告,指出找不到活动类。 这似乎不太好,它是......启动活动时应用程序停止。
此活动是我项目的一部分,其他活动没有问题。然而,其他 3 个活动导致相同的结果,它们都继承自无法链接的超类。
这里是导致问题的主要活动的代码
// Set the listener
m_gridView.setOnItemClickListener(new OnItemClickListener() {
public void onItemClick(AdapterView<?> parent, View v,
int position, long id)
{
final Intent i = new Intent(getApplicationContext(), ScreenChoiceActivity.class);
i.putExtra(ScreenChoiceActivity.EXTRA_SCREEN_ID, m_screensIdList[position]);
startActivity(i);
}
});
我已经试过了:
- 清理项目
- 检查所有库以便导出
- 更改库的顺序
- 使活动不抽象,因为它是
- 强制在内存中安装 apk
我现在没有想法
编辑: ScreenChoiceActivity 已注册到清单中
<application
android:allowBackup="true"
android:icon="@drawable/ic_launcher"
android:label="@string/app_name"
android:theme="@style/AppTheme"
android:uiOptions="splitActionBarWhenNarrow" >
<activity
android:name="com.blueskycorner.thousandwords.MainActivity"
android:label="@string/app_name"
android:screenOrientation="landscape" >
<intent-filter>
<action android:name="android.intent.action.MAIN" />
<category android:name="android.intent.category.LAUNCHER" />
</intent-filter>
</activity>
<activity
android:name="com.blueskycorner.thousandwords.ScreenChoiceActivity"
android:label="@string/title_activity_screen_choice"
android:parentActivityName="com.blueskycorner.thousandwords.MainActivity"
android:screenOrientation="landscape" >
<meta-data
android:name="android.support.PARENT_ACTIVITY"
android:value="com.blueskycorner.thousandwords.MainActivity" />
</activity>
.......
【问题讨论】:
标签: android noclassdeffounderror