简体   繁体   中英

i get this error after update Android Studio

FAILURE: Build failed with an exception.

  • What went wrong: The supplied javaHome seems to be invalid. I cannot find the java executable. Tried location: C:\Program Files\Android\Android Studio\jre\bin\java.exe

  • Try:

Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output. Run with --scan to get full insights.

I have found 3 links where people faced the same or something similar to what you are having. I hope these help: :)

IntelliJ Gradle Plugin: The supplied javaHome seems to be invalid

Android Studio - supplied javaHome is not a valid folder

The supplied javaHome seems to be invalid

This solution worked for me:

If someone faces this error after Android Studio update to Android Studio Electric Eel | 2022.1.1 than simply follow following steps:

  1. Go To Android Studio directory (default C:\Program Files\Android\Android Studio ) and remove jre folder.
  2. Run cmd as administrator.
  3. Write: cd C:\Program Files\Android\Android Studio
  4. Write mklink /D "jre" "jbr"

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM