Most of the people who work with Xamarin’s Mono for Android in Visual Studio 2012 face a bug where Intellisense doesn’t work for AXML in source view.

One of the fix which worked for me is mentioned below.

  1. Launch Visual Studio 2012
  2. Open a solution with .AXML file in it
  3. Now XML main menu should be visible on top
  4. Open “Schemas…” menu
  5. Sort by “File Name” column and see if “android-layout-xml” and “schemas.android.com.apk.res.android” are there. If found, skip to step 13
  6. If not found, go to “Program Files” if 32-bit system or “Program Files (x86)” if 64-bit system.
  7. Then go to “\MSBuild\Novell” or “\MSBuild\Xamarin\Android”
  8. You should be able to see 2 files “android-layout-xml.xsd” and “schemas.android.com.apk.res.android.xsd”
  9. Copy these 2 files to “\Microsoft Visual Studio 11.0\Xml\Schemas”
  10. Again open the “Schemas…” menu as mentioned in steps 3&4
  11. Now click “Add…” button and add these 2 files which should be located as mentioned in step 7 & 8
  12. Now restart visual studio and the XML editor for design layout should work fine with Intellisense
  13. From step 5….
  14. If above steps don’t work, then close the Visual Studio 2012.
  15. Now open “Developer command prompt for VS2012″ under Windows programs menu.
  16. Type “Devenv /ResetSettings” without quotes.
  17. Launch Visual Studio 2012 and see if Intellisense works.
  18. If still not working, better go to Xamarin  forums and post there.

注意:visual studio安装目录下会有一个 monodroidcatalog.xml文件,是好改成下面一样:[本人是64位,32位没有(86)]

<SchemaCatalog xmlns="http://schemas.microsoft.com/xsd/catalog">
<Schema href="%ProgramFiles(x86)%/MSBuild/Xamarin/Android/android-layout-xml.xsd" targetNamespace="http://schemas.android.com/apk/res/android" />
<Schema href="%ProgramFiles(x86)%/MSBuild/Xamarin/Android/schemas.android.com.apk.res.android.xsd" targetNamespace="http://schemas.android.com/apk/res/android" />

<Association extension="axml" schema="%ProgramFiles(x86)%/MSBuild/Xamarin/Android/android-layout-xml.xsd" />
</SchemaCatalog>

红色标记部分是我手动加上去的。保存此文件后本人重启vs,然后新建一个.axml文件后可爱智能提示就出来了。。

Xamarin开发Android时Visual Studio 2012没有智能提示解决办法的更多相关文章

  1. Xamarin C# Android for Visual Studio 平台安装

    原文:Xamarin C# Android for Visual Studio 平台安装 Xamarin是基于Mono的平台,目前主要有以下产品(更具体请见:http://xamarin.com/pr ...

  2. Xamarin C# Android for Visual Studio 平台安装笔记参考

    Xamarin是Mono创始人Miguel de Icaza创建的公司,旨在让开发者可以用C#编写iOS, Android, Mac应用程序,也就是跨平台移动开发. 简介 Xamarin是基于Mono ...

  3. VS2017 Xamarin开发Android时首次部署完成后直接闪退

    项目属性切换到Android选项,在打包属性上有一个[使用共享运行时]的选项要取消勾选,默认打钩时apk文件比较小,但程序无法运行起来. 取消后安装包一小变成几十M,这个目前好像没什么好的解决办法,毕 ...

  4. 【处理手记】VS2010SP1安装不上Visual Studio 2010 SP1 SDK的解决办法

    想写个VS插件,需要安装VS的SDK,VS2010SP1对应的SDK自然是Visual Studio 2010 SP1 SDK,下载页面: https://www.microsoft.com/en-u ...

  5. Visual Studio不显示智能提示代码,快捷键Alt+→也不出现

    最近安装了Dev Express的控件,我的vs2017 Enterprise版的环境,智能提示补全代码的快捷键功能,好像被修改了,不能使用了. 我原来的时候,比如在代码中输入如下代码: Consol ...

  6. 通过Typings为Visual Studio Code增强智能提示功能

    缘起 最近在学习Node.js及ThinkJS这个框架,用vscode作为开发环境.默认情况下vscode对ThinkJS的代码提示并不好,所以研究了一下,原来可以同通过Typings来让vscode ...

  7. ArcGIS 10.2 二次开发,兼容Visual Studio 2012二次开发,完美安装教程

    GIS 经常安装是常有的事,每次重装系统都要浪费大半天去安装这个.所以凑这一次安装,把这个软件重新安装的步骤整理了一下,希望对大家有所帮助.这次整理的内容的关键优点是,对常见的出错内容进行了归纳整理. ...

  8. Android项目更换开发环境时出现的 java.lang.VerifyError 异常解决办法

    from://http://blog.csdn.net/wudiwo/article/details/7548451 项目是从同事的电脑上直接拷贝过来的,项目里面的jar包是在项目跟下libs里面存放 ...

  9. MyEclipse设置像visual studio一样的智能提示

    打开 Eclipse  -> Window -> Perferences -> Java -> Editor -> Content Assist, 在右边最下面一栏找到 ...

随机推荐

  1. caffe之(四)全连接层

    在caffe中,网络的结构由prototxt文件中给出,由一些列的Layer(层)组成,常用的层如:数据加载层.卷积操作层.pooling层.非线性变换层.内积运算层.归一化层.损失计算层等:本篇主要 ...

  2. Java 代码优化过程的实例介绍

    衡量程序的标准 衡量一个程序是否优质,可以从多个角度进行分析.其中,最常见的衡量标准是程序的时间复杂度.空间复杂度,以及代码的可读性.可扩展性.针对程序的时间复杂度和空间复杂度,想要优化程序代码,需要 ...

  3. UVA 11737 Extreme Primitive Society

    非常容易的一个题: 只要判断两种基因相差的最小值就行: #include<cstdio> #include<cstring> #include<algorithm> ...

  4. PHP unlink() 函数

    定义和用法 unlink() 函数删除文件. 若成功,则返回 true,失败则返回 false. 语法 unlink(filename,context) 参数 描述 filename 必需.规定要删除 ...

  5. MySql 命令积累

    一. 修改表的自增起点 ; 二.获取自增键值 1. select max(id) from tablename 2.SELECT LAST_INSERT_ID() 函数 LAST_INSERT_ID ...

  6. jsp空页面导致的jvm heap溢出

    为了性能测试需要,写一个了简单的jsp页面: <%@ page contentType="text/html;charset=UTF-8" language="ja ...

  7. 【无聊放个模板系列】HDU 3068 MANACHER

    #include<cstdio> #include<cstdlib> #include<cstring> #include<iostream> #inc ...

  8. Ubuntu zookeeper-3.5.0-alpha启动错误 zkEnv.sh: Syntax error: "(" unexpected (expecting "fi")(转)

    昨天小猿我把Ubuntu Server64位上的 zookeeper换成了最新版本的,结果启动的时候出错:之前zookeeper-3.3.6是没有任何问题的,换成了zookeeper3.5出现了下面的 ...

  9. RxJava开发精要4 – Observables过滤

    原文出自<RxJava Essentials> 原文作者 : Ivan Morgillo 译文出自 : 开发技术前线 www.devtf.cn 转载声明: 本译文已授权开发者头条享有独家转 ...

  10. Medium上关于git的文章

    rebase和merge的正确使用时机 https://medium.com/@porteneuve/getting-solid-at-git-rebase-vs-merge-4fa1a48c53aa ...