title: Cannot open file, path = 'assets/responseFile' (OS Error: No such file or directory, errno = 2)
body: <p>I am trying to write on the existing txt file that was stored in a assets in android Studio. But, it throws error</p>
  
  <pre><code>assets:
    - assets/responseFile.txt
  </code></pre>
  
  <p>here is my code:</p>
  
  <pre><code>String content =  response.body.toString();
  String path = "assets/responseFile.txt";
  var file = new File(path);
  file.writeAsString(content);
  </code></pre>
  
  <p>I have also tried this way. But no luck</p>
  
  <pre><code>writingFile(String content) async {
    Directory appDocDir = await getApplicationDocumentsDirectory();
    String filePath = '${appDocDir.path}/assets/responseFile.txt';
    new File(filePath).writeAsString(content);}
  </code></pre>