06-18-2024 12:42 PM
I have this below code, but the output csv contains \n instead of giving line break
$id + '\n' + $crse_detail.toString().replace(/;/g, '\t\t').replace(/,/g, '\n') + '\n' + '**********' + '\n'
I tried updating the csv formatter delimiter to \n. It errored out saying line break can not be a delimiter.
Any suggestions?
Solved! Go to Solution.
06-19-2024 01:59 AM - edited 06-19-2024 02:28 AM
I am guessing you do not actually want a csv output but some sort of text file, based on that the content should be separate lines and then each block separated with the stars?
If you have some other challenge please provide some sample input and maybe a mockup on what you expect out..
I think you will only need to map the line as in your code above but in order to output the text with line breaks you can join all lines with \n and then push it as binary out to a file.
I have attached a sample for you to test with..
06-19-2024 01:59 AM - edited 06-19-2024 02:28 AM
I am guessing you do not actually want a csv output but some sort of text file, based on that the content should be separate lines and then each block separated with the stars?
If you have some other challenge please provide some sample input and maybe a mockup on what you expect out..
I think you will only need to map the line as in your code above but in order to output the text with line breaks you can join all lines with \n and then push it as binary out to a file.
I have attached a sample for you to test with..
06-20-2024 11:30 AM
THANK YOU SO MUCH!!! This worked great!