title: Android 6 - Programmatically copy an app file to another folder
body: <p>I have an app running in Android 6 that streams data in from a BLE device.  This works fine when using something like:</p>
  
  <p>myFile = new File(getExternalFilesDir(filepath), MyData);</p>
  
  <p>The resulting file is at a location that looks like:</p>
  
  <p>Filepath: /storage/emulated/0/Android/data/my_package/files/my_file</p>
  
  <p>I'd like to copy this file to a new folder that is not buried in the mass under the Android/data directory so a user can easily find and retrieve the data connecting to a phone/tablet via the USB cable.  So far, I've been unable to figure out how to do this ... or if it's even possible.  Anything I try seems to result in a permission exception.  </p>
  
  <p>I'd like this folder to be at the same level as ~/Android/data if possible.  If not, are there any alternatives?  Such as putting the data out on the SD card.</p>
  
  <p>I've read through many posts and articles on the Android file system.  It's all very confusing and vague.  And new versions of Android seem to change the way things work.  If anyone knows of a clear and concise explanation relative to Android 6 (Marshmallow) (maybe even with working examples!) please let me know.</p>
  
  <p>Thanks,  Max</p>