You need to sign in to do that
Don't have an account?
HAZLITT VASUDEVAN
how to get output nextline?
String a = 'Hello. \n Welcome to salesforce, \n Name \n Asian Paints \n WO Number \n 12345678 \n Account Id \n 1547586597';
List<String> lst = new List<String>();
lst=a.split('\n');
System.debug(lst);
output I got in a same line with a comma.
List<String> lst = new List<String>();
lst=a.split('\n');
System.debug(lst);
output I got in a same line with a comma.
Instead of \n you can directly use the \r\n in String.
( OR you can use the below code )
Thanks,
Maharajan.C
All Answers
Try Below Code Please Mark It As Best Answer If It Helps
Thank You!
Instead of \n you can directly use the \r\n in String.
( OR you can use the below code )
Thanks,
Maharajan.C