Search code examples
javaxamarinxamarin.formsjavac

Xamarin: Java SDK doesn't contain a valid version number


I'm not able to build app for android because I get a Warning:

Failed to get the Java SDK version as it does not appear to contain a valid version number. javac -version returned: ```java version "10" 2018-03-20.

and an Error:

Error MSB4044: The "AdjustJavacVersionArguments" task was not given a value for the required parameter "JdkVersion".

It was fine before I downloaded newer version of Java, jdk-10. The old version which seem to be working was jdk-1.8.


Solution

  • Make sure that you have the right path of JDK in the Android Settings tab, on Windows should be something like: C:\Program Files\Java\jdk1.8.0_152