I’d like to store an array of floats (lets say it will be around 5000 floats) to my sdcard. Later I’d like to put my file of float on my resources app so a new app can use those floats for later processing. Can I do this?? Is there any example I could use to do so? Which file extension would be best to use?
Thanks!
First, you will need to add the appropriate permission to your AndroidManifest.xml file:
You will also want to check (at runtime) if the device running your application has available external storage:
Finally, you can write the file by doing something like the following…
As stated before, a ‘.bin’ or ‘.dat’ extension is fine.