Ad

'Resource' Does Not Exist In Current Context

I am working on an Android-Xamarin App with Visual Studio 2015. After I think it was the next-to-last Visual Studio Tools for Xamarin Update 4.8.0.754 I have a problem.

In the whole solution, the Resources are not found

The name 'Resource' does not exist in the current context.

As seen in this screenshot: enter image description here

A suggested potential fix is to "using Android;"

That does not help me at all, as seen in the next screenshot: enter image description here

Now the error message is

'Resource.Id' does not contain a definition for 'IDNAME'

Maybe you can help me with this problem :-)

As additional information: I also got the problem discussed in this thread: Xamarin Android project cannot build because R$anim.class is in use

These two problems occurred at the same time till now.


EDIT:

Suppose in my Solution, the Project where the Resources are missing is called "ProjectName.Client.Droid". In this Project, there are folders like "Activities", "Adapter", "Fragment", ..., AND "Resources"

In the code, I can choose for example "ProjectName.Client.Droid.Fragment", in this case, IntelliSens even suggests ".Fragments" if I type "F"

I see every folder in the project except the Resources folder.

ProjectName.Client.Droid.Fragments      // works
ProjectName.Client.Droid.Resources      // not found
Ad

Answer

Meanwhile, this bug is fixed by updating VisualStudio and Xamarin.

Ad
source: stackoverflow.com
Ad