Hello all developer.
i’m new in uipath and c#
i have issue. I extract data from some website. then we have data table right.
but deta in data table is like
and in write line show
I need to remove “\n” because i need value inside \n$$$$\n.
I try use indexof find “\n” it not found.
I try use replace(“\n”) it not found.
I try use “\r\n”,environment.newline
please help me i try to search and try to do.
10 Likes
Hi @Saroch_Kamjikong,
if you have tried all what you said, you should try with “Split String” actitivity. Split it with “/n” and then use the index of the result array.
Bests,
Pablo
Thank for reply.
I will try to do. and update
Hi, I am also new in uipath. You can try with String.Replace(text, “[\r\n\t]”, “”) to remove \n.
indra
(Indra)
6
@Saroch_Kamjikong Can you share what error you are getting
Hi @Saroch_Kamjikong, use:
itemOut.Replace(Environment.NewLine,"")
Take care.
1 Like
Share the workflow, please.
indra
(Indra)
11
@Saroch_Kamjikong Change your variable x now its in type generic to string type
@Saroch_Kamjikong, change:
x = itemOut.ToString.Replace(Environment.NewLine,"")
And change x to String.
@indra @Bernardo_Ferreira


it still. what i’m wrong?
Please paste here what the robot is print in the Console, please.
That way I can test it.
PS: I don’t have access to the Silk website.
@Saroch_Kamjikong, go with:
x = System.Text.RegularExpressions.Regex.Replace(itemOut,"[\n]","")
17 Likes

Awesome!!!
pls explain why can’t use itemOut.Replace()
and than you every one.
@Saroch_Kamjikong Nice. Please mark my post as a solution.
1 Like
Pablo_Sanchez
(Pablo Sánchez Hernández)
19
@Saroch_Kamjikong
As I said in my post, you also can use Split String, take a look (just for have more options to resolve the issue):

test.xaml (5,0 KB)
1 Like
thank you so much.
i will try learning.
and sorry for my eng.
1 Like