Storing Strings : 

```
Encryption encryption = Encryption.getDefault("Key", "Salt", new byte[16]);
                String encryptedP = encryption.encryptOrNull(Password);
                String encryptedU = encryption.encryptOrNull(Username);    
            SharedPreferences prefs = PreferenceManager.getDefaultSharedPreferences(MainActivity.this);
            Editor edit = prefs.edit();
            edit.putString("Password", encryptedP);
            edit.putString("Username", encryptedU);
            edit.commit(); 

```

Retrieving Strings : 

```
Encryption encryption = Encryption.getDefault("Key", "Salt", new byte[16]);
    String encryptedP = encryption.encryptOrNull(Password);
    String encryptedU = encryption.encryptOrNull(Username);
    SharedPreferences sPrefs = PreferenceManager.getDefaultSharedPreferences(LoginActivity.this);
    String UsernamePref = sPrefs.getString("Username", "");
    String PasswordPref = sPrefs.getString("Password", "");
    if(encryptedU.equals(UsernamePref) &&  (encryptedP.equals(PasswordPref))) {  if((NewPassword.matches (ConfirmPassword))) {
                Editor edit = sPrefs.edit();
                edit.putString("Password", encryptedN);
                edit.commit();          

```

When retrieving, unless i am retrieving the last strings stored, it will not succeed as it will not look on all lines. Only the first line, how do i change this so that it scans every line before closing file ? 
Thanks 

Edit : Okay so i just realised its overwriting each time, not actually storing it onto a new line, which is why it can't retrieve "old strings", new question. How do i store and not overwrite each time i create a new user ?