0

SCENARIO

I undo all my pending changes, and get latest version from TFS. I attempt to build my solution and I get errors to do with two assemblies, these are:

  • System.Web.Helpers
  • System.Web.WebPages

assembly errors

A different member of my team does the same as me and for her it all builds fine and the assemblies are found with zero issues.

Our web.config is the same since we both check that out of TFS.

WHAT I HAVE DONE

I asked her for the path to where the two troublesome DLLs sit on her machine, and checked the same path on my machine, they exist. I have those DLLs in the same folder and they are the same version as hers!

C:\Program Files (x86)\Microsoft ASP.NET\ASP.NET Web Pages\v1.0\Assemblies\

I also compared our projname.csproj.user file to check and see if she had anything different in hers after I read this topic. But that too was the same as mine!

I then proceeded to remove the dlls, then adding them manually from the path above, and now all my errors are gone, but I then get told that my web.config has changed and needs to be checked in, and I know what has changed:

<Reference Include="System.Web.Helpers, Version=1.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35, processorArchitecture=MSIL">
  <HintPath>C:\Program Files (x86)\Microsoft ASP.NET\ASP.NET Web Pages\v1.0\Assemblies\System.Web.Helpers.dll</HintPath>
  <Private>False</Private>
</Reference>

The above used to be a on line, without the HintPath stuff.

I don't want this to be checked in, and it is really tiring to have to remove this stuff each time I want to check-in my code into TFS.

PROBLEM

System.Web.Webpages and System.Web.Helpers are not being loaded on my machine, but are on my other team member's machine.

DeanOC
  • 7,142
  • 6
  • 42
  • 56
J86
  • 14,345
  • 47
  • 130
  • 228

1 Answers1

0

possible reason is dll was registered on your colleagues machine. So it didn't have any HINTPATH. As per MSDN "Assemblies registered in the GAC won't have a HintPath entry for those references". Make sure this referenced assembly is registered on the GAC on all computers that you are trying to build the project on.

Register your dll and then try again.

amit dayama
  • 3,246
  • 2
  • 17
  • 28
  • OK, just asked my colleague to check her GAC folder, and them assemblies are not present there. – J86 Sep 21 '15 at 10:27
  • last thing which strike my mind is.. you should compare the .sln and .csproj /.vbproj file of yours and your colleague. – amit dayama Sep 21 '15 at 10:35