The feature recursive patterns is currently in preview, to use preview feature, please select preview version
switch (transactionRecieved)
{
case TransactionType.TransactionName.ToString():
break;
case TransactionType.TransactionName1.ToString():
break;
}
I am not using anything new. This is the general scenario and we use it all time like this for enum
TransactionType
is a enum
I also went through this post not found it useful.SO Post
I need to use enum in swith statement and I am not able to use it. could anyone help me on that part