Android - Reading Character in a Text File
<p>I want to read every character in a text file. For example I have a text file which contains the following text "John 26 Canada" and I want to read every Character so that I can put each String into its specific text view. This would be the output.</p>

<p>Name    : John
Age     : 26
Country : Canada</p>

<p>I have this code in saving data into text file.</p>

<pre><code>private void performSaveFile(String f) {
    // this does the actual file saving.
    // set the filename in the interface:

    EditText name = (EditText) findViewById(R.id.etName);
    EditText age = (EditText) findViewById(R.id.etAge);
    EditText country = (EditText) findViewById(R.id.etCountry);
    String strFileContent = name.getText().toString()
            + age.getText().toString() + country.getText().toString();

    // ... and save the file:
    try {
        FileOutputStream oStream = openFileOutput(f, Context.MODE_PRIVATE);
        oStream.write(strFileContent.getBytes());
        oStream.close();
    } catch (FileNotFoundException e) {
        e.printStackTrace();
    } catch (IOException e) {
        e.printStackTrace();
    }
}
</code></pre>
