

Within the Browse For Folder dialog box, navigate to C:\Program Files\Microsoft\jdk-11.0.12.7-hotspot, then click OK.Within the JDK Configuration dialog box, select the Configure an existing JDK installation (Advanced Users) radio button, then click the Browse button.This presents the JDK Configuration dialog box: Within the right-hand panel of the Options dialog box, click the … button next to the Java Development Kit Location path.Within the left-hand tree of the Options dialog box, select Xamarin > Android Settings:.Once JDK-11 has been installed, the JDK path can be configured within Visual Studio. Once an appropriate JDK-11 installer has been downloaded it, install JDK-11. We recommend using the Microsoft Build of OpenJDK: If you have not already installed JDK-11, download a JDK-11 installer. Note: the Android Designer is incompatible with Java SDK 11.0: If Visual Studio is not configured to use JDK-11 and $(TargetFrameworkVersion)=v12.0, then the build will fail with an XA0031 error:Įrror XA0031: Java SDK 11.0 or above is required when using $(TargetFrameworkVersion) v12.0. JDK-11 will not be installed by default in Visual Studio 2019 and Visual Studio for Mac 8.10. Install JDK-11 and Configure Visual Studio to use JDK-11 In Visual Studio for Mac 8.10, the Xamarin.Android Designer will display: In Visual Studio 2019, the Xamarin.Android Designer will display: xml file is opened within the Xamarin.Android Designer, the renderer will display an error message. When Visual Studio is configured to use JDK-11 and a layout. The Xamarin.Android Designer does not work with JDK-11.

Xamarin.Android Designer when JDK-11 is used When Visual Studio 2019 or Visual Studio for Mac 8.10 is configured to use JDK-11, certain Visual Studio features will not work properly. the Xamarin.Android Designer at the same time. It will not be possible to target Android 12.0/API-31 and use e.g. See the JDK 11-Caused Regressions section for details. However, configuring Visual Studio 2019 or Visual Studio for Mac 8 to use JDK-11 will prevent other features from working correctly.

To use the APIs added in Android 12/API-31, the following steps must be done: Xamarin.Android 12.0 adds support for Android 12/API-31.
