title: DownloadManager in Android (xamarin) throw Java.Lang.IllegalArgumentException
body: <p>In quite some time now, i have been trying to download a file through <a href="http://androidapi.xamarin.com/?link=T:Android.App.DownloadManager" rel="nofollow noreferrer">DownloadManager</a>. There are lots of examples on how to do that in android, but for xamarin i am not so lucky.</p>
  
  <p>I've created an application with minimal API v15 (4.0.3)  and checked that Mono.Android.dll is referenced. Also added the permissions <code>INTERNET</code>and <code>WRITE_EXTERNAL_STORAGE</code></p>
  
  <pre><code>DownloadManager dm;
  dm =  (DownloadManager)GetSystemService (Context.DownloadService);
  DownloadManager.Request request = new  Android.App.DownloadManager.Request (Android.Net.Uri.Parse ("https://www.adress));
  request.SetDestinationUri (Android.Net.Uri.Parse (EXTERNAL_DIRECTORY));
  var c = dm.Enqueue (request);
  </code></pre>
  
  <p>Every time when i hit <code>dm.Enqueue (request);</code> there is an error that occurred:</p>
  
  <p><img src="https://i.stack.imgur.com/wI0Kd.png" alt="enter image description here"></p>
  
  <p>I also try to set <code>SetDestinationInExternalPublicDir</code>or <code>SetDestinationInExternalPublicDir</code> no success.</p>
  
  <p>...oh and this is my directory</p>
  
  <blockquote>
    <p>const string EXTERNAL_DIRECTORY =
    Android.OS.Environment.ExternalStorageDirectory.AbsolutePath +
    "/MyAppFolder";</p>
  </blockquote>
  
  <p>I don't know what am i going wrong,please help me with that.</p>