VS 2015 Xamarin: Warning IDE0006 Error encountered while loading the project

33,055

Solution 1

I just followed the instructions but it did not eradicate the warning, although I ignored it, it does not appear now.

  1. When rebuilding the project, I noticed it takes a long time because it downloads a zipfile on your %userprofile%/AppData/Local/Xamarin/zips/*

-Make sure to not interrupt the build because it will stop downloading and will cause an invalid zip later on, thus reproducing this issue?

  1. Another hypothesis is that I included a component(referenced a dll) and then deleted it, and then re-added it. (as I'm having trouble with intellisense)

Solution 2

Firstly, it's not an 'Error' it's a warning.

Here's what actually happens:

  • Visual studio/xamarin check for required sdkbuild tools for your project
  • If you have it already in your SDK then no problem
  • If not, your project will show above warning in most of project cases.

How to fix this :

  • Clean your solution
  • Rebuild it (at this stage visual studio will automatically try to download zips)
  • If you get Rebuild canceled error, then close visual studio and start again
  • At this stage it will definitely download required zips.
  • Again Clean -> Rebuild -> Build -> Close the visual studio and open it again

Or Simplest alternative is

Download all SDKBuild tools available.

Your warning will be gone.

Let me know if it works, coz its worked for me several times.

Solution 3

I had this error also. The error was totally my fault, I was adding some strings to my strings.xml file and accidentally left an empty item in there

<string name=""></string>

This broke the R.java file in a really bad way, as the string/resource didn't have a name/id this is how it was created within R.java.

public static final int =0x7f080060;

As you can see it's missing its identifier. The moral of the story is: check all of your XML for any errors.

Solution 4

I too had both Intellisense and compilation issues.

On my Xamarin Forms and Android project, what worked for me is checking out the Resource.Designer.cs file in my Android project, quitting Visual Studio, and then re-opening it.

Hope that helps somebody.

Share:
33,055
trycatch
Author by

trycatch

whatever remains, must be the solution.

Updated on April 26, 2020

Comments

  • trycatch
    trycatch about 4 years

    I am developing an Android app using Xamarin.

    Visual Studio shows this warning, and I don't know what it means. I've followed the instructions but I can't seem to find the temp\\file

        Severity    Code    Description Project File    Line    Suppression State   Detail Description
    Warning IDE0006 Error encountered while loading the project. Some project features, such as full solution analysis for the failed project and projects that depend on it, have been disabled.   daijoubu-app        1   Active  To see what caused the issue, please try below.
    
    1. Close Visual Studio
    2. Open a Visual Studio Developer Command Prompt
    3. Set environment variable “TraceDesignTime” to true (set TraceDesignTime=true)
    4. Delete .vs directory/.suo file
    5. Restart VS from the command prompt you set the environment varaible (devenv)
    6. Open the solution
    7. Check 'C:\Users\Noli\AppData\Local\Temp\\daijoubu-app_*.designtime.log' and look for the failed tasks (FAILED)
    

    The full source is available on github.

  • CodeArtist
    CodeArtist about 8 years
    do you remember what was the name of the dll you referenced? Because personally (in my two computers) i have problems with mono's System.ObjectModel.dll. Somehow VS2015 does not recognize it and appears with a yellowish icon under the droid project references.
  • BrainSlugs83
    BrainSlugs83 over 7 years
    This error happens with a brand new blank Xamarin app. Not really sure what Java or strings.xml files you are talking about, since those doesn't exist here. Are you sure you're replying to the right question?
  • Phil
    Phil over 7 years
    your comment makes no sense. I'm pretty sure that by default a strings.xml file is always generated for you, Resources -> values -> strings.xml. I was just posting some advice as if you have any xml errors it can really screw with the xamarain/android build process.
  • BrainSlugs83
    BrainSlugs83 over 7 years
    In a new Xamarin.Forms project there is no file in the Droid Project (or the solution) named strings.xml -- there is a file there named styles.xml at that location, is that what you mean? -- or maybe it's been changed? -- Anyway, right now the OP's issue happens with a brand new File->New->Project->Blank Xaml App (Xamarin.Forms.Portable) project -- it's definitely not caused by any manual editing that the end user has done, since nothing has been edited yet.
  • Derek Foulk
    Derek Foulk over 7 years
    Can you elaborate on what you mean by "checking out the Resource.Designer.cs file"? I don't understand what you did there... Did you just open it? Did you reset the file via Git? I am having the same issues and it's driving me crazy...
  • luckyShubhra
    luckyShubhra almost 7 years
    @CodeArtist after you can clean your solution warning disappears. You can also remove System.ObjectModel from your references and again add it again. Clean and build warning disappears.
  • luckyShubhra
    luckyShubhra almost 7 years
    In my case I updated my Xamarin Forms to latest stable version to get rid of the warning.