mob*_*gic 1 android android-assets
我有一个counter.txt在我的Android项目的assets文件夹中命名的文件.在运行时,我想覆盖文件的内容.但它并没有反映出来.我该如何解决这个问题?
我使用了以下代码.
String FILENAME = "counter.txt";
String string = "hello world!";
FileOutputStream fos = openFileOutput(FILENAME, Context.MODE_PRIVATE);
fos.write(string.getBytes());
fos.close();
Run Code Online (Sandbox Code Playgroud)
| 归档时间: |
|
| 查看次数: |
2353 次 |
| 最近记录: |