Reputation: 1163
I'm using Cordova 5.1 and when i ran cordova emulate android
i get this error :
Running command: cmd "/s /c "c:\Users\Soheil\Desktop\phoneGap\hello\platforms\an
droid\cordova\run.bat --emulator""
ERROR: Error: Please install Android target: "android-18".
Hint: Open the SDK manager by running: C:\Program\ Files\ (x86)\Android\android-
sdk\tools\android.BAT
You will require:
1. "SDK Platform" for android-18
2. "Android SDK Platform-tools (latest)
3. "Android SDK Build-tools" (latest)
Error: cmd: Command failed with exit code 2
at ChildProcess.whenDone (C:\Users\Soheil\AppData\Roaming\npm\node_modules\c
ordova\node_modules\cordova-lib\src\cordova\superspawn.js:134:23)
at ChildProcess.emit (events.js:110:17)
at maybeClose (child_process.js:1015:16)
at Process.ChildProcess._handle.onexit (child_process.js:1087:5)
here's my sdk manager :
Any idea ? Thanks
Upvotes: 0
Views: 219
Reputation: 137
The problem is, that according to your screenshot you have installed Android 4.1.2 (API 16) but your program requires Android 4.3 (API 18). If you download the appropriate files you should be good to go.
Upvotes: 1