我试图从设备的/ data文件夹中附加文件.
我在/ data文件夹中成功创建了“abc.txt”,我可以在那个地方看到该文件.
我使用下面的代码发送电子邮件:
Intent intent = new Intent(Intent.ACTION_SEND);
intent.setType("text/plain");
intent.putExtra(Intent.EXTRA_EMAIL, new String[]{abc@gmail.com});
intent.putExtra(Intent.EXTRA_STREAM,
Uri.parse(Environment.getDataDirectory()+"/abc.txt"));
intent.putExtra(Intent.EXTRA_TEXT, "hello..");
startActivity(Intent.createChooser(intent, email_chooser_title));
但我无法收到附件..
PL.让我知道我做错了什么
谢谢.