Hi,
I am reading the data from xlsx file and one of the column value is “A” and changed each the value in each ron like “A”(row 1), “C”(row 2), “R”(row 3) …
I need to change the string output like if “A” then replaced to “Alpha” or “C” then “Cat” or “R” then “Red”.
you want to replace Column Values??
Yes please, in one statement like .replace(“A”, “Alpha”, “C”, “Cat”, “R”, “Red” ) like this
okay
Read Range and get Output as OutDataTable
use ForEachRow pass OutDataTable
use IF condition like is row(“yourColumName”).Contains(“A”)
the
row(“yourColumName”) = “Alpha” and so on
Main.xaml (10.2 KB)
Chech this sample
Thank you Pradeep!, with out IF condition is there any other way to string manipulation ?
yes
StringVar.Replace(“OldValue”,“NewValue”)
This is replace only 1 value, i need to replace multiple string’s at a time like .replace(“A”, “Alpha”, “C”, “Cat”, “R”, “Red” ).
you need to put it inside a for each activity
variable1.replace(“{A}”,“Alpha”).replace(“{C}”,“Cat”).replace(“{R}”,“Red”)
1 Like
Thanks Pradeep!, will try this.
1 Like