php - Java: AlertDialog not printing new line -


my app using alert dialog box display message obtained php file.

the message couple of strings, , box should display like:

string 1 string 2 string 3 

however displaying like:

string 1string 2string 3 

i've tried various ways add in new line, both php end , on java end. here have far:

protected void onpostexecute(list<string> result)     {         string message="";         for(int =0; i<result.size(); i++)         {             message+=result.get(i)+"\n";         }         alertdialog.setmessage(message);         alertdialog.show();     } 

i obtaining correct strings php file, newline not printing. there other way can that? tried resize box didn't @ all.

use system.lineseparator(); newline

message += result.get(i) +system.lineseparator(); 

Comments

Popular posts from this blog

ubuntu - PHP script to find files of certain extensions in a directory, returns populated array when run in browser, but empty array when run from terminal -

php - How can i create a user dashboard -

javascript - How to detect toggling of the fullscreen-toolbar in jQuery Mobile? -