在我的应用程序中,我必须使用Intent.setClassName或setComponent在另一个包中启动一个活动。当我使用Intent.setClass时,没有任何问题,如 Intent intent = new Intent(getApplicationContext(),org.iustb.knowledebase.animation.transparent.MainTransparentActivity.class); 在网络上解决这个问题的建议是在AndroidManifest的目标活动中添加或android:exported =“true”,但它不起作用。 有没有人可以帮助我?
我写了下面的代码:目标活动的权限拒绝:启动意图
Intent intent = new Intent();
intent.setClassName(cursor.getString(pIndex), cursor.getString(cIndex));
startActivity(intent);
清单文件设置:
<activity android:name="org.iustb.knowledebase.animation.transparent.MainTransparentActivity"
android:exported="true"></activity>
你能不能从后'LogCat',该输出将帮助我们给你更好的答案。 – 2012-08-13 08:28:02