Could not load file or assembly 'Microsoft.Web.Infrastructure,

后端 未结 20 2085
走了就别回头了
走了就别回头了 2020-12-09 00:57

I tried to upload my web site to a server. It was working fine with my local host, so I uploaded everything in my localhost wwwroot folder to the server and cha

20条回答
  •  误落风尘
    2020-12-09 01:09

    It turns out after doing a Reference Cleaning, it removed Microsoft.Web.Infrastructure, but not from the packages.config file. After trying to add it again using the Package Manager Console, Visual Studio says that it is already installed which is false because it was removed.

    I then removed the line of code in the packages.config file

    
    

    and ran the command again

    PM> Install-Package Microsoft.Web.Infrastructure
    

    After this, now it works fine.

提交回复
热议问题