I have a .csv file which the client first asked me to change the separator commas by vertical bars "|"
Now they are asking me to change it by tab delimiter but I can not do it. I have searched for several options but I can not find anything.
Here is the code I have so far:
string Arch = File.ReadAllText(newFileName); //newFileName es el archivo csv
Arch = Arch.Replace(@",""", @"|""");
File.WriteAllText(newFileName.Substring(0, newFileName.Length - 4) + "_Pipping.csv", Arch);
I have tried to replace the @"|""" por @"\t"""
but the tabulation does not work. Only export the symbol \ t between each column.
As an example of input and output text.
Input text:
"Username", "FullName"
Output text:
"UserName" "FullName"
How could I make this change?
Thanks