I want to share some text and image on Facebook. The code for that is -:
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());
}
}
But when sharing on Facebook it is only showing image and no description. I think there is some problem with setType(image/*). So can somebody tell what will be the solution. Thanks in advance.