Conflicting versions of ASP.NET Web Pages
Hello Aaron,
I have a project based on yours and it is giving me and error. I get the same error when I try running your riginal code. The application always crashes with : „Conflicting versions of ASP.NET Web Pages“.
This issue did not come up with an older version of the project, I still have downloaded. I tried to figure out the differences between the two versions and found out that some libraries have been updated or added. However according to References you only added Microsoft.AspNet.WebPages.3.0.0, bud did nothing with the "web.config" files.
I created a new project and I think there is something missing in the web.config of your project.
The following part was in the newly created web.config but not in Sample MVC:
<runtime>
<assemblyBinding.....
<dependentAssembly>
<assemblyIdentity name="System.Web.WebPages" publicKeyToken="..........." /> <bindingRedirect oldVersion="1.0.0.0-2.0.0.0" newVersion="2.0.0.0" />
</dependentAssembly>
Also :
<compilation debug="true" targetFramework="4.5">
<assemblies> .....
<add assembly="System.Web.WebPages, Version=1.0.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35"/>
</assemblies>
</compilation>
I am not a programming guru, but could this be what causes the crashes? I think, there are two possible solutions.
- Creating a new project (MVC4? Not sure), copy-pasting the code from the old project and trying if it works.
- Editing the current web.config.
I think the first solution might be easier.
Have you tried setting up Visual Studio NuGet to automatically download missing packages on build?
See here: http://docs.nuget.org/docs/workflows/using-nuget-without-committing-packages
This idea missed me. I will do this way. However, It is strange, that standard download by NuGet window or Package Manager console don´t resolve this problem.
I was find similar (same) problem here http://forums.asp.net/t/1878600.aspx?How+to+create+a+flipcart+like+panel+for+showing+products+in+gridview
I try but did not help It.
Did you try start project SampleMVC in webbrowser, after upgrade libraries?
I just recently merged in / accepted the idea of making this a smaller package by not including all those binaries in this previous request: https://github.com/aarondcoleman/Fitbit.NET/pull/12
Not everyone who uses this library wants / needs he ASP.NET sample and all the binaries, some just want the library as a serverside component or desktop app for instance. In that sense, it made sense to rely on the new Nuget ability to resolve / download those missing packages.
After you enable automatic restoring then yes, you should be able to build and then run SampleMVC.
--Aaron
When I was desperate and depressed, because I wasn´t able to make working. My colleague try download projekt and say "There must be something very bad with dependencies, because It is not work, too". We will see in Monday, when I am on my PC. If still not work, I will write to you :yum: