This is what I did seems to be working fine for me
class Program
{
public enum cond
{
checknum,
checkval
}
static private void data()
{
cond condtype = cond.checknum;
switch (condtype)
{
case cond.checknum:
Console.WriteLine("I am checknum");
break;
case cond.checkval:
Console.WriteLine("I am checkval");
break;
default:
Console.WriteLine("I am no one");
break;
}
}
static void Main(string[] args)
{
data();
Console.ReadKey();
}
}
I suggest you look at other areas of the code for the problem.
HTH