I have a text file that I need to parse. I need to be able to check the result of a line if it has char(28)char(13)...when read lines via below it strips out the control characters and gives me an empty string...Is there a better way to search for control charcters in a file?
var _endMessage = string.Format("{0}{1}", Convert.ToChar(28).ToString(), Convert.ToChar(13).ToString());
foreach (string line in File.ReadLines(_logFile.FullName))
{
if (Regex.Match(line, _endMessage)
{
// Do something here
}
}
Thanks