title: Unable to create external directory
body: <p>I am unable to create a directory in the external storage folder.  I have created a new project, modified the manifest and added the code as seen below.  Any help would be greatly appreciated. I updated my post to include that the code provided below does not work.  The only thing I can think is the emulator is the problem.  I am running Nexis API 32 x64.</p>
  
  <p><strong>AndroidManifest.xml</strong></p>
  
  <pre><code>&lt;?xml version="1.0" encoding="utf-8"?&gt;
  &lt;manifest package="com.us.foobar"
            xmlns:android="http://schemas.android.com/apk/res/android"&gt;
  
      &lt;uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE" /&gt;
  
      &lt;application
          android:allowBackup="true"
          android:icon="@mipmap/ic_launcher"
          android:label="@string/app_name"
          android:supportsRtl="true"
          android:theme="@style/AppTheme"&gt;
          &lt;activity
              android:name=".MainActivity"
              android:label="@string/app_name"
              android:theme="@style/AppTheme.NoActionBar"&gt;
              &lt;intent-filter&gt;
                  &lt;action android:name="android.intent.action.MAIN"/&gt;
  
                  &lt;category android:name="android.intent.category.LAUNCHER"/&gt;
              &lt;/intent-filter&gt;
          &lt;/activity&gt;
      &lt;/application&gt;
  &lt;/manifest&gt;
  </code></pre>
  
  <p><strong>Source:</strong></p>
  
  <pre><code>public void mkdir() throws Exception
  {
      String root = Environment.getExternalStorageDirectory().getAbsolutePath();
      String dir = root + "/Foobar";
  
      File file = new File(dir);
      if (!file.exists())
      {
          if (!file.mkdirs())
          {
              throw new Exception("Unable to create application data directory.\r\n\r\nDirectory: " + dir);
          }
      }
  }
  </code></pre>