Updating the Android SDK with Visual Studio 2013 and Xamarin 3

I had a few minutes this morning before one of my classes and thought I’d start working with the new Xamarin 3, which looks freaking awesome, by the way.

I opened visual Studio 2013 and created a new Xamarin.Forms application.  Before I make any changes, I decided to verify that it would indeed compile with out issues (I’ve had problems like this before).

This is what I got:

Could not find android.jar for API Level 19. This means the Android SDK platform for API Level 19 is not installed. Either install it in the Android SDK Manager (Tools > Open Android SDK Manager…), or change your Xamarin.Android project to target an API version that is installed. (C:\Users\Mitch\AppData\Local\Android\android-sdk\platforms\android-19\android.jar missing.)

Very clear as to what the issue is, but the instructions to fix the problem are not exactly correct.  I found this page on the Xamarin developer site:

http://developer.xamarin.com/recipes/cross-platform/ide/launch_sdk_manager/

Which mostly pointed me to where I needed to be. 

Here are the revised instructions for correcting this issue with Xamarin 3.0 and Visual Studio 2013:

1. Select Tools, Open Android Emulator Manager.

image

2. Click on the Tools menu.

image

3. Click on Manage SDK…

image

It will investigate your current environment then recommend a list of packages to update.

4. Select the packages you wish to install then click the Install X packages button. (X is the number of updates).

image

5. Accept the License then click the Install button.

image

The update process will take several minutes to complete, depending on the number of updates.

6. After the update has completed (mine took more than an hour, with 14 updates), close the SDK Manager and return to Visual Studio.

7. Rebuild your project and you should be good to go.

Leave a Reply 1 comment