Tag Archives: write

23,397 views

Write new file or append text Java Android example

BufferedWriter, FileWriter, write, close MODE_APPEND Java and Android example Write to file Android example try { String MYFILE = "my_file"; String strText = "My text";   // MODE_APPEND, MODE_WORLD_READABLE, MODE_WORLD_WRITEABLE // create new file or rewrite existing FileOutputStream fos = … Continue reading

Posted in Android Examples Code | Tagged , , , | Comments Off on Write new file or append text Java Android example
7,108 views

Preferences settings save open read write application Android example

Android app setup preferences, settings, open, read, write, onStop(), onPause(), getSharedPreferences(), SharedPreferences.Editor getInt(), getBoolean(), getString() , putInt(), putString(), putBoolean() example source code.   import android.content.SharedPreferences;   public class MainClass extends Activity { public static final String PREFERENCES_NAME = "MyPrefsFile"; String … Continue reading

Posted in Android Examples Code | Tagged , , , , , , , , | Comments Off on Preferences settings save open read write application Android example