title: Android: How to specify location of writing a file
body: <p>I want to store the created file of this code somewhere in my sdcard (i.e. sdcard/myfiles/file/)</p>
  
  <pre><code>    final String TESTSTRING = new String("Hello Android");
  
      FileOutputStream fOut = openFileOutput("samplefile.txt", MODE_WORLD_READABLE);
      OutputStreamWriter osw = new OutputStreamWriter(fOut); 
  
      osw.write(TESTSTRING);
  
      osw.flush();
      osw.close();
  </code></pre>
  
  <p>I'm new to java and android dev, many thanks for any help! :)</p>