Answers for "replace backslash with double backslash in c#"

C#
0

replace double backslash with single backslash c#

string path = "C:\Hg\temp\\LogFile.txt";
string output = path.Replace(@"\\", @"\"); 

output >>>
C:\Hg\temp\LogFile.txt
Posted by: Guest on April-22-2020

C# Answers by Framework

Browse Popular Code Answers by Language