无法在xamarin中创建Android项目

时间:2016-07-22 09:46:17

标签: android visual-studio-2012 xamarin sdk android-ndk

我已经安装了使用Xamarin的2012年视觉工作室。我正确设置了JDK,sdk和ndk路径。我甚至将JAVA_HOME路径正确设置为jdk 1.7。当我尝试创建新的Android项目时,它给出了一个错误“对象引用未设置为对象的实例”。输出如下

[I:sdk]:                  Looking for Android SDK..
[I:sdk]:                    Key HKCU\SOFTWARE\Novell\Mono for Android\AndroidSdkDirectory not found.
[I:sdk]:                    Key HKLM\SOFTWARE\Novell\Mono for Android\AndroidSdkDirectory found:
    Path does not contain adb.exe in \platform-tools (C:\android-sdk-windows).
[I:sdk]:                    Key HKCU\SOFTWARE\Xamarin\MonoAndroid\PrivateAndroidSdkPath not found.
[I:sdk]:                    Key HKCU\SOFTWARE\Android SDK Tools\Path not found.
[I:sdk]:                    Key HKLM\SOFTWARE\Android SDK Tools\Path found:
    Path contains adb.exe in \platform-tools (C:\Users\Arnold\AppData\Local\Android\android-sdk).
[I:sdk]:                  Looking for Android NDK..
[I:sdk]:                    Key HKCU\SOFTWARE\Novell\Mono for Android\AndroidNdkDirectory found:
    Path contains ndk-stack.exe in \. (C:\Users\Arnold\AppData\Local\Android\android-ndk).
[I:sdk]:                    Key HKLM\SOFTWARE\Novell\Mono for Android\AndroidNdkDirectory not found.
[I:sdk]:                    Key HKCU\SOFTWARE\Novell\Mono for Android\JavaSdkDirectory not found.
[I:sdk]:                    Key HKLM\SOFTWARE\Novell\Mono for Android\JavaSdkDirectory not found.
[I:sdk]:                  Looking for Java 6 SDK..
[I:sdk]:                    Key HKLM\SOFTWARE\JavaSoft\Java Development Kit\CurrentVersion found.
[I:sdk]:                    Key HKLM\SOFTWARE\JavaSoft\Java Development Kit\1.6\JavaHome not found.
[I:sdk]:                    Key HKLM\SOFTWARE\JavaSoft\Java Development Kit\1.7\JavaHome found:
    Path contains jarsigner.exe in \bin (C:\Program Files (x86)\Java\jdk1.7.0_71).
[I:Unknown]:              Found Android SDK. API levels: (none)
[I:Unknown]:              Found Xamarin.Android 6.0.2

2 个答案:

答案 0 :(得分:0)

尝试在此处更新android SDK作为解释Object refrence not set to an instance of an object When I create new Android App (Visual Studio)

请务必参考最新的Android SDK

答案 1 :(得分:0)

我尝试过更新的sdk。由于某些技术问题,无法从android studio更新sdk。所以我直接从

下载了单独的组件

http://downloads.puresoftware.org/files/android/

尝试此链接下载Xamarin所需的一切