无法在Facebook应用上共享文本和图像在Android应用程序
问题描述:
我想在Facebook上分享一些文字和图像。代码是: -无法在Facebook应用上共享文本和图像在Android应用程序
public void clickShareBtn(View view){
try
{ Intent i = new Intent(Intent.ACTION_SEND);
i.setType("image/*");
i.putExtra(Intent.EXTRA_SUBJECT, "My application name");
String sAux = "\nLet me recommend you this application\n\n";
sAux = sAux + "https://play.google.com/store/apps/details?id=com.krsna \n\n";
i.putExtra(Intent.EXTRA_TEXT, sAux);
Uri uri = Uri.fromFile(convertBitmapToFile(bmp));
i.putExtra(Intent.EXTRA_STREAM, uri);
startActivity(Intent.createChooser(i, "choose one"));
}
catch(Exception e) {
Log.i("Radhe", e.toString());
}
}
但是,当在Facebook上分享时,它只显示图像和没有说明。我认为setType(image/*)存在一些问题。那么有人可以告诉我们什么是解决方案。提前致谢。
http://stackoverflow.com/questions/23541823/how-to-share-text-and-image-on-facebook-using-intent – sasikumar
HTTP:/ /stackoverflow.com/questions/22533773/android-how-to-share-image-with-text-on-facebook-via-intent – sasikumar