23

I am trying to create a new Blank App (Android) in Visual Studio 2015 with installed Xamarin, Android SDK and Android emulator. When trying to create a new Project, I just get a popup with the message:

Value cannot be null. Parameter name: path1

Solution Explorer is empty and just a empty folder is created in Projects folder.

How can I solve it?

William Barbosa
  • 4,936
  • 2
  • 19
  • 37
Parham.D
  • 1,158
  • 2
  • 12
  • 31
  • It seems that Visual Studio cant take the path of the project, for now to workaround it you can try creating an empty project on xamarin and then open it from Visual Studio and see if everything work ok – CDrosos Sep 17 '15 at 00:28

7 Answers7

14

Go to Xamarin Studio Tools-->Options-->SDK

Give the proper locations and restart Visual Studio.This worked for me

Vijay
  • 1,030
  • 11
  • 34
13

I encountered this issue because Visual Studio was unable to download the Android SDK due to network issues. Luckily, I already had an installation of the SDK because I have Android Studio installed. There are some 3rd party sources to download the SDK directly, but so far as I know the only official way is to install Android Studio.

Once the SDK is installed via one method or another, you need to supply the path to Visual Studio.

  1. From Visual Studio, open the Tools menu and select Options.
  2. From the Options dialog, expand the Xamarin menu on the left and choose Android Settings.
  3. Under Android SDK Location choose Change.
  4. Supply the location of your SDK.
    • Mine for Example was C:\Users\USER\AppData\Local\Android\sdk
Zach Olivare
  • 3,805
  • 3
  • 32
  • 45
  • in my case I already had android studio installed. Pointing it to the correct dsk was the fix, thank you :) – b15 May 29 '16 at 18:01
2

Visual Studio had a problem to install Android SDK tools completely. In Android SDK Manager I had just Android SDK tools, but VS need Android SDK Platform-tools too. I installed Platform-tools manually with Android SDK Manager, then VS could recognize adb.exe file in the Platform-tools folder. So the error disappeared and now Android projects create properly.

Parham.D
  • 1,158
  • 2
  • 12
  • 31
  • So which are steps to resolve it? Would mind to tell us? – NoWar Apr 06 '16 at 15:35
  • 1
    For men: In VS 2015 -> Tools -> Android -> Android SDK Manager. In the opened window, select Android SDK Platform-tools in Tools category. Then just click the Install Packages button. Good Luck. – Parham.D Apr 07 '16 at 06:00
  • Thanks. But I cannot see VS 2015 -> Tools -> Android I see only VS 2015 -> Tools -> Xamarin.... Do I missing soimething in VS2015 ? – NoWar Apr 07 '16 at 10:47
  • When you install vs you have to select android options , like SDK and so on. Now you can do it in add/remove programs in control panel. – Parham.D Apr 09 '16 at 12:34
  • Can you provide the download link to Android SDK ? I tried repairing my VS15 twice but still it would not install Android SDK correctly. – Muhammad Ali Apr 21 '16 at 19:08
  • I downloaded the Android Studio from Google and it installed Android Studio. Later I just provided the path to Android SDK on VS15 and the green check appeared. Android Projects are created properly. Link for Android Studio ... http://developer.android.com/sdk/index.html#Other – Muhammad Ali Apr 21 '16 at 20:34
1

In Visual Studio 2015 Community Tools->Options->Xamarin choose change next to Android SDK Location. Assuming you have already installed the Android SDK, perhaps during an Android Studio installation, browse to the Android SDK Location.

If you do not know where the Android SDK is installed and you have installed Android Studio 2.0 then open Android Studio and read the path at Tools->Android->SDK Manager->Android SDK Location.

In my case, the SDK was installed to %userprofile%\appdata\local\android\sdk.

Greg Bogumil
  • 1,903
  • 15
  • 23
1

For VS2015, Tools > Options > (options screen pops up) > Xamarin > Android Settings

Click change on "Android SDK Location" to enter the SDK path.

I already had Android Studio installed with an up-to-date SDK, so I used the same path to avoid duplication. The path was; "C:\Users[my windows user name]\AppData\Local\Android\sdk"

dunwan
  • 1,577
  • 2
  • 16
  • 14
1

in visual studio 2015 go to -> (tools->option->Xamarin) choose android sdk (chenge) get path name that sdk android you downloaded and apply it;

amir1996
  • 11
  • 1
0

Sometimes the SDK might not be installed due to proxy issues. Open up the SDK manager and Click on Tools > Options and enter Your proxy path and port (without http prefix) and then Click on the Package menu > Reload. This will load the SDKs. From here You can install the SDKs You need. Then go to Visual Studio 2015 and Click on Tools > Options > Xamarin and the Browse to the SDK Path. Usually C:\Program Files (x86) \Android \ Android SDK if You installed for all users on Machine, and C:\User..\App Data if You installed for just one user.

Bikey
  • 935
  • 7
  • 12