【发布时间】:2012-08-03 15:24:39
【问题描述】:
我正在尝试使用 ACTION_SEND_MULTIPLE Intent 同时共享视频文件和文本。
现在,这在 GMAIL 中有效(附件中的视频和邮件正文中的文本),但是我也想在 Whatsapp 中做同样的事情,但它没有出现在意图的应用程序列表中。
我的代码是下一个:
Intent sharingIntent = new Intent(Intent.ACTION_SEND_MULTIPLE);
sharingIntent.putExtra(Intent.EXTRA_TEXT, "Descarga la app en...");
ArrayList<Uri> contenidos = new ArrayList<Uri>();
File file = new File(Environment
.getExternalStorageDirectory()
.getAbsolutePath()
+ "/Talking/"
+ nombreVideo
+ ".3gp");
Uri screenshotUri = Uri.fromFile(file);
contenidos.add(screenshotUri);
//sharingIntent.putExtra(Intent.EXTRA_STREAM,screenshotUri);
sharingIntent.putParcelableArrayListExtra(Intent.EXTRA_STREAM, contenidos);
sharingIntent.setType("video/3gpp");
startActivity(Intent.createChooser(sharingIntent, "Share video using"));
感谢您的帮助。
【问题讨论】:
标签: android video text android-intent share