title: How can I send an email with an attached file with android's intent?
body: <p>I'm trying to send an email with an attached file. The file in internal storage, so this is my code:</p>
  
  <pre><code>File filelocation = new File(getFilesDir().getAbsolutePath()+"/MyApp", "FileName");
          Uri path = Uri.fromFile(filelocation);
          Intent emailIntent = new Intent(Intent.ACTION_SEND);
          emailIntent .setType("vnd.android.cursor.dir/email");
          String to[] = {"mailmailmail@gmail.com"};
          emailIntent .putExtra(Intent.EXTRA_EMAIL, to);
          emailIntent .putExtra(Intent.EXTRA_STREAM, path);
          emailIntent .putExtra(Intent.EXTRA_SUBJECT, "Subject");
          startActivity(Intent.createChooser(emailIntent , "Send email..."));
  </code></pre>
  
  <p>But I obtain always: <code>Permission denied for file</code>.</p>
  
  <p>How can I solve it??</p>