Storing and retrieving data in processing for Android – #2 by Sikorsky – Processing for Android

Hi, my name is Alex.

I came in contact with processing through Arduino a few years ago Since then I have been using processing for personal projects and a as a programming learning tool. A great experience.

Now I decided to take it to Android (not using APDE, still using the desktop processing IDE) and I’m having an issue with storing data in the device.

I know in java mode, the default directory for reading is the data folder, but when you save files the default directory is the sketch folder. When you need to modify a let’s say a setting files, all you have to do is include the path. Not a big deal.

My problem is that my app reads the settings files ok every time, but it does not overwrite it with the new settings. So every time I open the app it loads the same settings, not the user’s preferences. When I try to add the path to the file name, like I would do in Java mode, I get an Android error (File name contains separators error). I am not using external storage btw…

I’m just using loadStrings() and saveStrings().

Any idea? Thank you in advance. =)

Read more here: Source link