BuildTasks.Csc task could not be loaded from the assembly?

后端 未结 21 915
北荒
北荒 2020-12-13 05:15

I feel guilty asking a question like this around here, but I\'m at a loss and would appreciate some help.

A proof-of-concept like web application was built on one PC

相关标签:
21条回答
  • 2020-12-13 05:50

    In my case, the solution was:

    Use Windows Explorer and navigate to the offending path: C:\MyApplication\Code\Main\ABCProject\ABCProject.UI\Bin

    Right click on bin folder > select properties > Uncheck ReadOnly.

    0 讨论(0)
  • 2020-12-13 05:50

    I moved my solution from one drive to another, and one of the files could not be copied because "in used", for which I click ignored, producing the error described in this post. Copying the missing file manually fixed it.

    file: Microsoft.Build.Tasks.CodeAnalysis.dll Destination directory: packages\Microsoft.Net.Compilers.2.1.0\tools

    0 讨论(0)
  • 2020-12-13 05:52

    I delete all from packages folder and rebuild solution. It's worked for me.

    0 讨论(0)
  • 2020-12-13 05:54

    I just tried this on a clean install of a Windows 10 machine and the issue for me ended up being that I didn't have the .NET 3.5 framework installed. This stackoverflow question helps explain why.

    Cannot build WIX project on windows 10

    0 讨论(0)
  • 2020-12-13 05:58

    I too tried the top answer with no luck so deleted the contents of my bin and packages dir, closed and re-opened VS and everything fine now.

    0 讨论(0)
  • 2020-12-13 06:00

    It turns out that NuGet packages were committed to the repository and breaking everything. Deleting the project\project\packages directory from the repo solved all build problems since NuGet fetches the packages automatically on build.

    0 讨论(0)
提交回复
热议问题