在程序中启动微信一直出现这个错误Unable to find explicit activity class { com.tencent.mm /com.tencent.mm.ui.LauncherUI}; have you declared this activity in your AndroidManifest.xml?
代码:
Intent intent = new Intent();
ComponentName cmp = new ComponentName(" com.tencent.mm ","com.tencent.mm.ui.LauncherUI");
intent.setAction(Intent.ACTION_MAIN);
intent.addCategory(Intent.CATEGORY_LAUNCHER);
intent.addFlags(Intent.FLAG_ACTIVITY_NEW_TASK);
intent.setComponent(cmp);
startActivity(intent);