如何将我的应用程序重定向到其他应用程序,如facebook android studio?

问题描述:

我想知道我可以重定向我的应用程序到另一个应用程序,我正在使用android studio,我是一个biginner,我搜索了一个解决方案,但我没有找到。 我想我的应用程序重定向到另一个其控制我的IP摄像机如何将我的应用程序重定向到其他应用程序,如facebook android studio?

为此,你应该使用意图https://developer.android.com/training/basics/intents/sending.html

Intent launchIntent = getPackageManager().getLaunchIntentForPackage("com.package.targetapp"); 
if (launchIntent != null) { 
    startActivity(launchIntent); 
} 
+0

只是为了澄清,“com.package.yourapp”应该是目标应用的文件包,而不是你的应用。 –

+1

的确,我会重命名它以避免混淆。谢谢 –

+0

如果我想重定向到facebook我有什么包在迪? – Yasmine