解决方法:发生意外错误,正在初始化Android Designer. Xamarin在VS 2015中 [英] How to resolve : unexpected error occured Initializing Android Designer" in VS 2015 with Xamarin

查看:167
本文介绍了解决方法:发生意外错误,正在初始化Android Designer. Xamarin在VS 2015中的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

使用Xamarin和VS 2015 Pro启动新PC时,出现以下错误:

Bringing up a new PC with Xamarin and VS 2015 Pro I received the following error:

尝试初始化Android Designer时发生意外错误. 请验证Android SDK路径和Java Development Kit路径 在工具->选项-> Xamarin-> Android设置菜单上.请查看日志 有关更多详细信息.

An unexpected error occurred trying to initialize Android Designer. Please verify the Android SDK path and the Java Development Kit path on Tools->Options->Xamarin->Android Settings menu. Please see the logs for more details.

我已验证SDK的安装正确. VS没有生成任何类型的活动日志,因此我认为该日志必须位于其他位置.任何人都知道我在哪里可以找到此日志,以查找有关错误的更多信息?

I verified the SDK's are installed correctly. VS didn't generate any kind of Activity Log so I believe the log must lie elsewhere. Anyone know where I can find this log to find out more about what is wrong ?

推荐答案

我遇到了与上述问题完全相同的问题(在装有新Visual Studio的新PC上),并且99.9%的人确定答案是如何应用更新.或者,更重要的是,当您认为它们是没有被应用时.

I had exactly the same problem described (on a new PC, with a new Visual Studio install) and am 99.9% sure the answer is in how updates are applied. Or, more importantly, how they aren't being applied when you think they are.

  1. 转到工具|选项| Xamarin |其他,在Xamarin下进行Visual Studio更新,现在检查STABLE更新.确保您至少运行4.2.0.680.当更新程序正在运行时,您将不得不在后台关闭Visual Studio,它会警告您. 从Visual Studio卸载和安装跨平台开发工具并没有为我应用此更新.我不得不强行解决这个问题.

现在,如前所述,转到工具",Android SDK Manager.我注意到我的"Android SDK工具"和跨平台工具"已经过时,并且有可用的更新.我接受并将更新应用到版本24.4.1. 与我同在,这就是棘手的地方-仍然无法正常工作.

Now, as mentioned earlier, go to Tools, Android SDK Manager. I noticed my "Android SDK Tools" and "Cross Platform Tools" were out of date and updates were available. I accepted and applied the updates to version 24.4.1. BEAR WITH ME, THIS IS WHERE IT GETS TRICKY--it still didn't work.

返回到工具,Android SDK Manager .我立即注意到,即使我刚刚应用了"Android SDK工具"的最新更新(24.4.1),现在仍然可以使用新版本(25.2.2)以及其他17个更新.我全部接受了.

Go back to Tools, Android SDK Manager. I immediately noticed that even though I'd just applied the latest update for "Android SDK Tools", (24.4.1), a new version (25.2.2) was now available, along with 17 other updates. I accepted them all.

宾果.在曾经有烦人的错误消息,空白的设计图面和带有悲伤的无可用控件"消息的工具箱的地方,现在有附加的屏幕快照-设计图面,可以在其中看到.axml的可视化表示形式,以及一个我可以从中拖放控件的工具箱,它们实际上会显示在我的Samsung平板电脑上.

Bingo. Where I once had the annoying error message and an empty design surface and an empty toolbox with the sad "no usable controls" message, I now have the attached screen snapshot--a design surface where I can see a visual representation of my .axml, and a toolbox from which I can drag and drop controls and they actually show up on my Samsung tablet.

抱歉,太冗长了.我在此问题上花费了数小时,并认为其他人可能会喜欢另一种可行的解决方案.

Sorry so verbose. I lost hours on this problem and thought others might appreciate another working solution.

这篇关于解决方法:发生意外错误,正在初始化Android Designer. Xamarin在VS 2015中的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆