![](/img/trans.png)
[英]Remove facebook permissions dialogs from my ANDROID app while sharing contents?
[英]Facebook on Android exits immediately when sharing with it from my app
当我与Facebook共享我的应用程序中的一些URL(作为文本)时,Facebook新帖子活动出现并立即退出,并且我的应用程序重新出现。 用户没有机会提交它,甚至没有机会查看并完成它。 (显然)这不是崩溃,没有关于Facebook应用程序崩溃的通知。 与其他应用程序(例如Gmail)共享时,它可以正常工作。
不幸的是,这仅在某些设备上发生。 我测试过的所有设备都具有相同版本的Facebook应用。 它与Android版本无关(已在两台4.4设备上测试过,其中一台还可以,另一台不可以)。
这是我在应用程序中所做的:
String textToShare = "http://lovelikeorhate.eu/question/LOVE/3";
Intent sendIntent = new Intent();
sendIntent.setAction(Intent.ACTION_SEND);
sendIntent.putExtra(Intent.EXTRA_TEXT, textToShare);
sendIntent.putExtra("com.facebook.platform.extra.APPLICATION_ID", getString(R.string.facebook_app_id));
sendIntent.setType("text/plain");
startActivity(Intent.createChooser(sendIntent, getResources().getText(R.string.send_to)));
任何想法可能有什么问题吗? 该网址启用了应用链接,可以关联吗?
该应用程序必须在Facebook上处于生产模式。 这是相同的问题: 在Android中打开Facebook共享图标时出现ClassNotFoundException
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.