Xamarin Forms.NETStandard 1.4 Resource Issue

I converted my PCL project from classic Xamarin forms to .NETStandard 1.4 and I have a resource problem (*. Resx)

Error CS0103 The name "Resource" does not exist in the current context. Prog1Utilities D: \ MyProjects \ Pro1 \ Pro1Utilities \ WebUtilities \ ApiService.cs 38 Active

How can i fix this?

Project.json

{
  "supports": {},
  "dependencies": {
    "Newtonsoft.Json": "9.0.1",
    "System.Net.Http": "4.3.0",
    "Xam.Plugin.Connectivity": "2.2.12",
    "Xamarin.Forms": "2.3.3.168"
  },
  "frameworks": {
    "netstandard1.4": {
      "imports": "portable-win+net45+wp8+win81+wpa8"
    }
  }
}
0
source share
2 answers

To make .resx work, you need to add the Microsoft.NETCore.Portable.Compatibility NuGet package. However, after that there are other problems with the construction. This is already a known issue, and people at Microsoft are working on it. I will update this message as soon as I get updates from them.

(Dec '16)

Xamarin .NET Standard Microsoft. , - , .

( '17)

, , Visual Studio 2017.

+4

dnxcore50 api . .

"frameworks": {
    "netstandard1.5": {
      "imports": "dnxcore50"
    }
  }
0

Source: https://habr.com/ru/post/1659978/


All Articles