This may be a basic question, but I googled it and didn't find an answer. I hope you will help me. Consider I have an enum ContactNumberType:
string[] names = Enum.GetNames(typeof(ContactNumberType))
If I use the above, the compiler gives no error, but when I write:
string[] names = Enum.GetNames(ContactNumberType)
It says:
ContactNumberTypeis a type but used like a variable.
While the type of ContactNumberType is Enum, as far as I know, and the argument of method GetNames needs EnumType, so whats the issue with that?