Примечание.
Для доступа к этой странице требуется авторизация. Вы можете попробовать войти или изменить каталоги.
Для доступа к этой странице требуется авторизация. Вы можете попробовать изменить каталоги.
Проблема
The Android SDK platform you are targeting only works with certain versions of Java. If you get this error, it means either:
- You don't have a Java SDK installed, or
- Your Java SDK version is too old or is otherwise not compatible with the targeted Android platform.
Решение
Make sure you install a compatible JDK version, such as the Microsoft Build of OpenJDK.
Примечание.
Java SDK 11.0 is required to use $(TargetFrameworkVersion) v12.0 (API-31) and later, and to use $(TargetFramework)=net6.0-android31.0 in .NET 6 and later.
Use of Java SDK 11.0 will break the Android Designer in Visual Studio 16.11 and earlier.
Примеры сообщений
error XA0031: Java SDK 11.0 or above is required when using $(TargetFrameworkVersion) v12.0.
Download the latest JDK at: https://aka.ms/msopenjdk
Note: the Android Designer is incompatible with Java SDK 11.0: https://aka.ms/vs2019-and-jdk-11