Android share intent for Pinterest not working

后端 未结 3 682
清酒与你
清酒与你 2020-12-07 00:23

I am doing an android share intent for Pinterest but is not fully working. I am able to attach the image but I can\'t send text to the \"description\" field in the share win

3条回答
  •  天涯浪人
    2020-12-07 00:30

    File imageFileToShare = new File(orgimagefilePath);
    
    Uri uri = Uri.fromFile(imageFileToShare);
    
    Intent sharePintrestIntent = new Intent(Intent.ACTION_SEND);
    sharePintrestIntent.setPackage("com.pinterest");
    sharePintrestIntent.putExtra("com.pinterest.EXTRA_DESCRIPTION", text);
    sharePintrestIntent.putExtra(Intent.EXTRA_STREAM, uri);
    sharePintrestIntent.setType("image/*");
    startActivityForResult(sharePintrestIntent, PINTEREST);
    

提交回复
热议问题