[Solved] Issue using switch case statement [closed]
valueArray is a multidimensional array of objects, according to your parameter definition. switch does not support that. You can’t and wouldn’t perform a switch on an array of values; switch operates on a single value. You can use foreach to flatten the array, iterate over each value, and apply the switch, however… As the error … Read more