Category Archives: Error

sdk\1.0.0-rc4-004771 Disappeared Creating a .Net Core project in VS2015

Error MSB4019 The imported project “C:\Program Files\dotnet\sdk\1.0.0-rc4-004771\Microsoft\VisualStudio\v14.0\DotNet\Microsoft.DotNet.Props” was not found. Confirm that the path in the declaration is correct, and that the file exists on disk. MyProject C:\Users\Paul\documents\visual studio 14\Projects\MyProject\Myproject\MyProject.xproj

This issue, on initial investigation, looks like a problem with the VS Tools location (defined here in the xproj):

  <Import Project="$(VSToolsPath)\DotNet\Microsoft.DotNet.Props" Condition="'$(VSToolsPath)' != ''" />

However, the fix was in the new file Global.json:

  "projects": [ "src", "test" ],
  "sdk": {
    "version": "1.0.0-preview2-003131"

When the project was migrated to VS2017, the global.json was changed to look like this:


So it looks like MS are moving away from the idea of these external project / solution state definition files. Which is a shame, because I really thought they were a good idea.


The “GenerateResource” task failed unexpectedly

I recently started getting this error on a solution:


It didn’t actually report any errors, other than this and, no matter what I tried (deleting the suo file, rebuilding, cleaning, etc.), it wouldn’t go away.

Finally, I ran up a command prompt and tried to compile it there. I immediately got this error:

MyViewModel.cs(63,28): error CS1056: Unexpected character ‘$’ [C:\Users\Paul\Desktop\MyApp\MyApp\kqlonrzo.tmp_proj]

Okay, so, the project definitely did use the new $ character. Here’s the thing, whilst I was trying to compile using VS2015, the version of the command prompt that I had run was 2012. The next thing was to try running the command prompt for VS2015.

This gave a less than useful error regarding `MyProject.csproj.metadata` file. So, next I tried compiling the project directly from the command line.

Finally, that worked. Unfortunately, I was unable to break the compile again. However, it isn’t the first time that I’ve encountered this error: hence this post.

So, whilst not proven, for next time, try compiling the solution using the command line and, if that doesn’t work, try compiling the individual project file first.