title: Open text file using ACTION_OPEN_DOCUMENT
body: <p>I'm trying to set an 'EditText' to the contents of a simple txt file. After looking at the developer page I stumbled across some code that gets a photo. I edited to what I thought would suit my needs but it doesn't work:</p>
  
  <pre><code>private void importText(){
      Intent intent = new Intent(Intent.ACTION_OPEN_DOCUMENT);
      intent.setType("text/*");
      intent.addCategory(Intent.CATEGORY_OPENABLE);
      startActivityForResult(intent, 0);
  }
  
  @Override
  protected void onActivityResult(int requestCode, int resultCode, Intent data) {
      if (requestCode == 0 &amp;&amp; resultCode == RESULT_OK) {
          String textContent = data.getDataString();
          mEditText.setText(textContent);
      }
  }
  </code></pre>
  
  <p>What this does is it puts the string name of what appears to be the files location in the <code>EditText</code> not the contents of it. My app right now only supports API 19 so I thought I would be able to use this as a feature. Is this function possible using <code>ACTION_OPEN_DOCUMENT</code> or do I need to do something else? </p>