Beshel Ikwen
Beshel Ikwen

Reputation: 161

Android installation issues

I have been trying to set up my android to begin my development lessons all day without success. I have installed the Java JDK kit and I'm trying to install the android sdk but this is the error I keep getting all day:

"failed to find java version for 'C:\windows\system32\java.exe':[2] The system cannot find the specified file.

The Java version I installed is jdk1.7.0_03. I have gone to the environment variables and added the path to the java file (C:\Program Files\Java\jdk1.7.0_03\bin and C:\Program Files\Java\jdk1.7.0_03\bin\javac) and I still get the same error. The android sdk version I am trying to install is "installer_r18-windows.exe". Can someone help me?

Upvotes: 16

Views: 13362

Answers (8)

Aman Chawla
Aman Chawla

Reputation: 304

To install Android and work with Android Studio on your first app, here are the step by step instructions:

  • Step 1: Download Android Studio
  • Step 2: Install Android Studio Step
  • Step 3: Start a new project
  • Step 4: Create new AVD
  • Step 5: Open AVD Manager
  • Step 6: Launch Emulator
  • Step 7: Run Project

Whereas while installing Android, you need to also set Environment variables.

To set Environment Variables, the same steps are followed while installing Java to set JDK.

Go to Control Panel > System > Advanced System Settings > Advanced tab > Environment Variables.

Under System Variable, click Path, then New and add the JDK path.

Upvotes: -2

Dapo
Dapo

Reputation: 1

This error often occur if not always because android sdk does not recognise "java" in sub-folder "System32" as "java.exe". Simply rename it to "java.exe". Sub-folder "System32" is found in Local Disk(C:)>>Windows. Scroll down to find "java" in sub-folder "System32".

This should work provided "Java jdk" is properly installed on your system. Goodluck!

Upvotes: 0

paramiao
paramiao

Reputation: 1

you just need delete the "java.exe" of "C:\windows\System32\", and reset the java environment(JAVA_HOME,CLASSPATH,PATH), then you will successful pass this step.

By the way , i am under Windows7 X64

Upvotes: 0

Raza Ahmed
Raza Ahmed

Reputation: 2751

@hasan-veli-soyalan I tried your solution, but my c:\windows\system\java.exe not exist in my case, I'm using Windows 8 pro 64bit, instead, i found c:\windows\system32\java.exe and i changed it as you described, it worked!!

Upvotes: 0

Hasan Veli Soyalan
Hasan Veli Soyalan

Reputation: 2508

The problem is there are two Java files and the installer picks the first one that it finds; The solution, however, is simple:

rename c:\windows\system\java.exe to c:\windows\system\java.exe.orj, then restart the installer, and everything should be fine.

It will now use the version of java.exe installed in Program Files\Java instead which solves the issue.

Upvotes: 62

mubashir9082
mubashir9082

Reputation: 115

I fixed this issue follow these steps:

  1. right click my computer->properties->advanced system settings->advanced tab->click environmental variable

  2. under system variales press new to create and new system variable

  3. give it name JAVA_HOME and give url to folder where java is installed

    e.g C:\Program Files\Java\jdk1.7.0_05 and then re-run sdk

Upvotes: 7

Maddoc
Maddoc

Reputation: 13

The only thing you had to do, was to set the path to the jdk source folder.

"C:\Program Files\Java\jdk1.7.0_03\"

That worked for me having that error.

Upvotes: 1

Jane
Jane

Reputation: 39

I had faced the same error while installing android, try system restore and then reinstall jre and jdk

Upvotes: -1

Related Questions