When Xamarin develops Android, Visual Studio 2012 does not have a smart tips solution

Source: Internet
Author: User

Most of the people who work with Xamarin's Mono for Android in Visual Studio-face a bug where Intellisense doesn ' t wo RK 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 is 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 is 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 is 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 and see if Intellisense works.
  18. If still not working, better go to Xamarin forums and post there.


Note: The Visual Studio installation directory will have a monodroidcatalog.xml file that is good to change to the following: [I am 64-bit, 32-bit No (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>

The red mark part is my manual addition. After saving this file I restart Vs and then create a new. axml file after the cute smart tip comes out.

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.