How to set Java SDK path in AndroidStudio?

前端 未结 8 2009
囚心锁ツ
囚心锁ツ 2020-12-08 03:37

I had Java 1.7.0_21 installed and I installed 1.7.0_45 today after uninstalling the previous version. Now Android Studio has stopped compiling projects and says that it cant

相关标签:
8条回答
  • 2020-12-08 04:24

    I tried updating all of my SDKs by just going into the Project Structure > Platform Settings > SDKs and changing the Java SDK, but that didn't work, so I had to recreate the configurations from scratch.

    Here's how to create your SDKs with the latest Java:

    1. In Project Structure > Platform Settings > SDKs, click the "+" button to add a new SDK.
    2. In the pop-up, go into your Android SDK folder and click "Choose"
    3. Another pop-up will appear asking for which SDK and JDK you want to use. Choose any Android SDK and the 1.7 JDK.
    4. Go to Project Structure > Project Settings > Project and change your Project SDK to the one you just created. You should see the name of the SDK contain the new Java version that you installed.
    0 讨论(0)
  • 2020-12-08 04:27

    Click "use embedded JDK" on version Android Studio 3.2.1

    0 讨论(0)
提交回复
热议问题