Following is the code snippet from a console application -
class MyClass { public int GetDay(string data22) { int returnValue = 0;
There is an "invisible" character at the beginning of your
string ExecutionDay = "THURSDAY";
and it is the LEFT-TO-RIGHT MARK. You can check it with:
int len = ExecutionDay.Length; // 9 instead of 8
and
char ch = ExecutionDay[0]; // 8206