Saturday, February 26, 2011

Android SDK cannot detect JDK

Normally I develop Android on Linux machine, and just tried to install the new version of Android SDK on my Windows 7 machine today. I download the exe version of Android SDK, installer_r10-windows.exe. And run it, it's complained by Android SDK Tools Setup that Java SE Development Kit not found. No matter how I config my Windows 7 and JDK!!!

Android SDK cannot detect JDK

Finally I found out the solution:
- Press Back button on the error page
- Press Next again.
- OK !!!

37 comments:

  1. After searching for an hour I found your post and it worked for me on both my Win7 & WinXP boxes.

    Thanks man!

    ReplyDelete
  2. Works like a charm. Thanks a million.

    ReplyDelete
  3. hi friend, thanks for your solution. I met this problem and it wastes me hours to solve

    ReplyDelete
  4. There is also problem with 64bit JDK - doesn't work with ADK, you must have 32bit JDK (same error is displayed).

    ReplyDelete
  5. Wasted so many hours because of this! This worked well for me! Thanks loads!!!

    ReplyDelete
  6. unbelievable!!!! i worked here for almost 2 hours to solve it, and that's only it ??? ¬¬ thanks guy, so thanks... :)

    ReplyDelete
  7. It worsk very smoothly.. Thanks for sharing.

    ReplyDelete
  8. Thanks so much dude....this saved my time...

    ReplyDelete
  9. i spent many hours to find the solution...anwy.tq so much.!:)

    ReplyDelete
  10. hi, I must say thanks to you. I spent about week to figure out this. Great full to you..

    ReplyDelete
  11. Hey,

    I'm using windows 7 64 bit and installed the java 1.7.0_03 verssion of JRE and JDK and had the same problem.

    I tried the "Back, Next" issue but it didn't work.
    I solve the problem by reinstalling the JRE and the JDK as an administrator
    by right clicking on the EXE files an choose "Run as administrator".
    after that the Android SDK installation found it with no problems.

    ReplyDelete
  12. Simply copy java.exe and javaw.exe from C:\Windows\System32 to C:\Windows\SysWOW64

    ReplyDelete
  13. Thanks, Emiliano. Copied to SysWOW64 and installing ok now.

    ReplyDelete
  14. Copying to SysWOW64 solved the problem. Thanks!

    ReplyDelete
  15. Can also create symbolic link if you don't want to copy the files. (requires administrator privileges):
    mklink C:\Windows\SysWOW64\java.exe C:\Windows\System32\java.exe
    mklink C:\Windows\SysWOW64\javaw.exe C:\Windows\System32\javaw.exe

    ReplyDelete
  16. Thanks...Actually error message is misleading. Installer was looking in Syswow64 folder. Just create symlinks as said in earlier comment by lennart.

    ReplyDelete
  17. This comment has been removed by the author.

    ReplyDelete
  18. Use forward slashes instead of backslashes in the JAVA_HOME variable and dont include bin as following

    C:/Program Files/Java/jdk1.7.0_06/

    ReplyDelete
  19. Emiliano! THANKS your tip worked

    ReplyDelete
  20. update the evnironment variable path from "C:\Program Files\Java\jdk1.7.0_09" to "C:\\Program Files\\Java\\jdk1.7.0_09\\bin"

    ReplyDelete
  21. Copying to java.exe and javaw.exe from C:\Windows\System32 to C:\Windows\SysWOW64 worked for me on Win7 64 Ultimate. Problem solved!

    ReplyDelete
  22. OK!, copying java.exe and javaw.exe to SysWOW64

    Thanks ninja!!

    ReplyDelete
  23. OP's idea didnt help. Copy files to sysWOW64 did the trick :D

    ReplyDelete
  24. Thanks bro. It's saved my time...

    ReplyDelete
  25. Everything i tried. Just clicking back and next wont help if jdk is already installed.
    Just run the Android sdk installation file by right clicking as Administrator.
    :-D

    ReplyDelete
  26. The solution is that we need to pay attention to what the software is requiring. The Android SDk require Java to be installed not only JDK. Java can be downloaded from this link https://www.java.com/en/download/ . Install it and that is all you need. Thanks

    ReplyDelete