Strange Build error after upgrading to Visual studio 2015 wants to copy pagefile.sys

I encountered the same issue.

The problem starts when you upgrade the DotNetCompilerPlatform to version 1.0.1.

To work around this issue you can downgrade to version 1.0.0 using the NuGet package manager.

EDIT: If you uninstall Microsoft.CodeDom.Providers.DotNetCompilerPlatform AND Microsoft.Net.Compilers, and then install the DotNetCompilerPlatform (has a dependency on the Microsoft.Net.Compilers package so it will automatically install that) package again the error disappears for good so it seems.

Still not sure what happens under water but I can work again!


I had the exact same problem. I didn't upgrade DotNetCompilerPlatform to 1.0.1.

My solution was...

  • Exit visual studio
  • Delete your solution's "packages" folder
  • Relaunch VS. The NuGet package manager console window will prompt to restore packages. Do it.
  • Build your solution

I used to have the same issue but I just removed Microsoft.CodeDom.Providers.DotNetCompilerPlatform and then installed 1.0.0. I found that after that it all looks good.