Vote count: 0
I'm using Android Studio and I'm trying to pass a multi-line EditText field to a JSON string.
The problem I'm having is that line breaks within the EditText aren't being formatted as "\n" when being passed to the JSON string and the JSON then breaks.
I can't figure out how to replace an actual line break, with "\n" from the EditText.getText() so I can pass it correctly to the JSON.
asked 18 secs ago
Replace new line with n in Java
Aucun commentaire:
Enregistrer un commentaire