hello I have a String and I need to remove all new line characters. I have remove enviroment.NewLine but some breaks still exist. I got string form get text activity.
I attach example for analization.
New Text Document (2).txt (16 Bytes)
Hi,
Did you try splitting the string on the basis ofa new line character or VbCrLf.
Thanks.
yes, I have try this and still newline presist.
can your try:
strCleansed = System.Text.RegularExpressions.Regex.Replace(yourStringVar, "\r|\n"," ")
Trythis
txtFileOutput.Split({Environment.Newline},StringSplitOptions.RemoveEmptyEntries)(0)
Hi @tomaz
- Use the following below syntax and store the output in an Array Variable say TextArray.
TextArray=str_Text.Split(Environment.NewLine.ToArray, StringSplitOptions.RemoveEmptyEntries)
- str_Text is the output variable of the text file read.
- Run an for each loop and you can find the expected output.
Note: Have attached the workflow for reference
Sequence1.xaml (7.3 KB)
Hope it helps!!
Regards,