What I have is a giant text file that contains a bunch of strings that are split by \\. The problem for me is there can be 5 \\ or 4 \\ o
\\
string last = inputString.Substring(inputString.LastIndexOf('\\') + 1);