Reference System.Web.WebPages.Razor, Version = 1.0.0.0. The system can not find the file specified

-1

We work at the company with the SNV with the projects.

One day the server stopped working, it was a job to recover the projects. But there is a project that has a reference error with the following message:

  

Could not load file or assembly 'System.Web.WebPages.Razor, Version = 1.0.0.0, Culture = neutral, PublicKeyToken = 31bf3856ad364e35' or one of its dependencies. The system can not find the file specified. **

The project is in ASP.NET MVC 3 . I already tried to download this package through nuget, make reference to web config . But to no avail. Someone can help.

    
asked by anonymous 25.07.2014 / 17:39

1 answer

0

In your Web.config file, check the following entry:

<configuration>
  <runtime>
    <assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1">
      ...
      <dependentAssembly>
        <assemblyIdentity name="System.Web.WebPages.Razor" publicKeyToken="31bf3856ad364e35" culture="neutral" />
        <bindingRedirect oldVersion="0.0.0.0-3.0.0.0" newVersion="3.0.0.0" />
      </dependentAssembly>
      ...
    </assemblyBinding>
  </runtime>
</configuration>

Note that oldVersion is the version range, while newVersion is the Version property of your Assembly. Check the entries and test again.

    
26.07.2014 / 00:08