It wasn't the code I showed that caused the error - it was what came, or
rather DIDN'T come, next. I had no break following the second case. I'll
try to claim it was the enum that confused me.
"Ramsey Schaffnit" <(E-Mail Removed)> wrote in message
news:%23%(E-Mail Removed)...
> Documentation for error message Compiler Error CS0163 says:
> Control cannot fall through from one case label ('label') to another
>
> Ok, fine.
>
>
>
> Documentation for switch statement says the same thing, but ALSO says:
>
> Although fall through from one case label to another is not supported, it
is
> allowed to stack case labels, for example:
> case 0:
> case 1:
> // do something;
>
> In the event, my code gets the CS0163 error on the following:
>
> switch {
>
> case dbType.dbtOracle:
>
> case dbType.dbtOracleMS:
>
> blah, blah;
>
> }
>
>
>
> So what's right? (And, yes, dbType is an enum.)
>
>
|