I want to use a switch statement using Strings in Android Studio (version 3.2.1), this should compile because I am using a java version of 1.7 or higher (1.8). Nevertheless it still doesn't work. It gives: Incompatible types. Found: 'java.lang.String', required: 'byte, char, short or int'
Asked
Active
Viewed 93 times
1 Answers
0
Actually it's clear, that's a problem with compiler settings in IDE.
Confirm once that you are using java 7 or higher.

Alien
- 15,141
- 6
- 37
- 57
-
This is essentially the same answer as the accepted answer to the dupe I flagged. – O.O.Balance Oct 13 '18 at 15:49