title: How to read the data in a Blob in WebView on Android?
body: <p>I have a server that creates an object blob on the browser and I want to download this within WebView in an Android app. I tried redirecting the request to the browser instance as well as using the download manager to do this, but neither of them seems to work (Even though if I open up the same page in Chrome, the download operation works there). </p>
  
  <p>I tried the following code,it throws error: </p>
  
  <blockquote>
    <p>Android.content.ActivityNotFoundException: No Activity found to handle Intent { act=android.intent.action.VIEW dat=blob:https%3A//111.111.111.111%3A8080/40b63131-63b1-4fa4-9451-c6297bbd111a" </p>
  </blockquote>
  
  <p>Edit</p>
  
  <blockquote>
    <p>Android.content.ActivityNotFoundException: No Activity found to handle Intent { act=android.intent.action.VIEW dat=blob:<a href="http://digitalinsensu.com/0f0d6127-a0f1-44c3-af85-72f648258d6d" rel="noreferrer">http://digitalinsensu.com/0f0d6127-a0f1-44c3-af85-72f648258d6d</a></p>
  </blockquote>
  
  <hr>
  
  <p>Code:</p>
  
  <pre><code>mWebView.setDownloadListener(new DownloadListener() {
  public void onDownloadStart(String url, String userAgent,String contentDisposition, String mimetype,long contentLength) {
      Intent i = new Intent(Intent.ACTION_VIEW);
      i.setData(Uri.parse(url));
      startActivity(i);
  }
  });
  </code></pre>
  
  <p>and this throws java.lang.IllegalArgumentException: Can only download HTTP/HTTPS URIs error:</p>
  
  <pre><code>mWebView.setDownloadListener(new DownloadListener() {
      public void onDownloadStart(String url, String userAgent,String contentDisposition, String mimetype,long contentLength) {
          DownloadManager.Request request = new DownloadManager.Request(Uri.parse(url));
          request.allowScanningByMediaScanner();
          request.setNotificationVisibility(DownloadManager.Request.VISIBILITY_VISIBLE_NOTIFY_COMPLETED);
          request.setDestinationInExternalPublicDir(Environment.DIRECTORY_DOWNLOADS, "download");
          DownloadManager dm = (DownloadManager) getSystemService(DOWNLOAD_SERVICE);
          dm.enqueue(request);
  
      }
  });
  </code></pre>
  
  <p>How should I be downloading the blob? Any help would be appreciated. </p>