I have a web app that uses DLLs from this folder:
C:\Program Files (x86)\Microsoft ASP.NET\ASP.NET Web Pages\v1.0
Lately, my HD crashed and I had to reinstall everything, but I've installed the latest version of Visual Studio.
I have tried installing every MVC version that exists (I now have version 1 to 3 installed and MVC 4 runtime) and still I get no v1.0 folder (only a v2.0).
My guess is that this came with an older version of Visual Studio or that MS has changed something on their MVC 1,2,3 installers and they don't include this package of DLLs.
Does anyone know how can I install all the files that v1.0 folder usually holds?
I have tried installing separate DLLs from it using nuget, but things got worse with mixed DLL versions.
OK. Here is what I have done:
I first installed AspNetMVC3ToolsUpdateVS11Setup.exe from here:
https://www.microsoft.com/en-us/download/details.aspx?id=1491.
This will add the v1.0 folder. This seems to be an old version, but that's the best I could find...
And then an installer called AspNetMVC3.msi, which I think came from here:
https://www.microsoft.com/en-us/download/details.aspx?id=44533
After that, it seemed working OK. :)
Related
I have a UWP project that was created using Visual Studio 2017. It builds fine on this machine (machine 1).
However, when I copy the project over to a machine (machine 2) where I only have the Visual Studio 2017 Build Tools installed, and attempt to build it using MSBuild, I get the following error:
C:\Program Files (x86)\Microsoft Visual Studio\2017\BuildTools\MSBuild\15.0\Bin\Microsoft.Common.CurrentVersion.targets
(1126,5): error MSB3644: The reference assemblies for framework ".NETCore,Version=v5.0" were not found. To resolve this
, install the SDK or Targeting Pack for this framework version or retarget your application to a version of the framewo
rk for which you have the SDK or Targeting Pack installed. Note that assemblies will be resolved from the Global Assemb
ly Cache (GAC) and will be used in place of reference assemblies. Therefore your assembly may not be correctly targeted
for the framework you intend. [<path_to_my_UWP_project>\UWP.csproj]
I suspect the need for .NetCore v5.0 arises from this line in my UWP.csproj file:
< PackageReference
Include="Microsoft.NETCore.UniversalWindowsPlatform" Version="6.0.1"
/>
I do a nuget restore before I build on machine 2, and I can see that microsoft.netcore.universalwindowsplatform successfully gets restored under < C_Users_me >/.nuget/packages, and so does microsoft.netcore.
On machine 1 however, only microsoft.netcore.universalwindowsplatform gets restored but it still builds fine via Visual Studio.
Question: Why am I getting this error and how do I fix the problem?
I was getting the same error message. The resolution was to install the latest version of Visual Studio 2019. I had version 16.6 installed on my computer. I needed version 16.8 installed. Once I did the install, the error message went away.
Initial reason for this issue: I had received a VS C# solution from another individual. Apparently there was something in the solution that stated it required some library (.NETFramework v=5.0) which was not in 16.4 but was in 16.8.
The help instructions on the VS error message did not help; there is currently no .NETFramework, version=v5.0. There is only a .NET Core Version=5.0 or a .NetFramework Version=v4.8
This gitHub post lead me to the correct soltuion.
I was chasing the exact same issue but for all I could see, I had the right SDK installed. As it turned out, I had caused the issue myself by placing a global.json in the root directory with the SDK version pinned to 3.1.404.
dotnet was honouring the global.json settings and hence could not locate the reference assemblies for 5.0.
Removing the global.json fixed the issue for me.
You need to use Visual Studio 2019 16.8 Preview 2 or newer to use .NET 5 Preview 8. .NET 5 Download it here https://learn.microsoft.com/en-us/visualstudio/releases/2019/release-notes-preview
The reference assemblies for framework .NETCore, Version=v5.0 were not found
According to the error log, it seems you are missing the .NET framework SDK (. NET core, v5.0) on your machine 2. You can check the it from following directory:
C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETCore\v5.0
To install it, make sure you are install following individual components:
If you still have that error, please try to copy the directory C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETCore\v5.0 from machine 1 to machine 2.
Hope this helps.
The below steps worked for me.
In Visual Studio open View -> Terminal and enter: dotnet new global.json
Open the root folder of the solution and edit the newly created file "global.json" the exact name of the .net version installed must be entered.
To view all installed .net core sdk's , enter dotnet --list-sdks in command.
add the correct version to the global.json file, the right-click solution, and select Restore Nuget Packages or restart the visual studio.
The global.json will look like this
See you have Microsoft Visual Studio v16.8 or above.
To update the VS version -> Help -> Check for Updates
This error is displayed if the .NET 5.0 SDK is not installed. Be careful, you must download the proper sdk:
dotnet-sdk-5.0.401-win-x64.exe or dotnet-sdk-5.0.401-win-x86.exe depending on your installation (in the case of Visual Studio Code or your Windows) In the path https: // dotnet.microsoft.com/download/dotnet/5.0 you can download.
I had the same error message
enter image description here
1- Open Visual Studio Installer
2- Updat the version of Visual Studio 2019 to 16.11 or Upper
3- Restart your Project
I'm trying to build my solution using TeamCity / MSBuild.
It's a WebAPI project which shares some entities in a PCL with a mobile client.
I see there are a few caveats around getting the PCL reference libraries installed on a buildserver, which I think I've sorted
(Building Portable Class Library Project in build server fails)
However, I'm getting an error during the build of the portable class library as follows:
[11:20:49][Doctrina.Pcl.Entities\Doctrina.Pcl.Entities.csproj] _GetSdkToolPaths
[11:20:49][_GetSdkToolPaths] GetSdkPropertyValue
*[11:20:49][GetSdkPropertyValue] C:\Program Files (x86)\MSBuild\Microsoft\VisualStudio\v14.0\AppxPackage\Microsoft.AppXPackage.Targets(975, 5): error APPX3212: SDK root folder for 'Portable 7.0' cannot be located. See http://go.microsoft.com/fwlink/?prd=12560&pver=1.0&plcid=0x409&ar=MSDN&sar=PlatformMultiTargeting&o1=Portable&o2=7.0 for more information.*
The "help" link doesn't go anywhere useful and it seems to be very google-resistant in terms of finding any resolution.
I don't have Visual Studio 2015 installed on the build-server at all, but I have installed PortableClassLibrary tools, copied the reference directory from my local PC over, etc, as per the other related SO question.
Help please?
I encountered this error when attempting to build portable projects targeting .NET Standard.
I managed to resolve it without installing Visual Studio on my build server, by copying from a machine that does have Visual Studio installed:
C:\Program Files (x86)\Microsoft SDKs\Portable\v14.0
C:\Program Files (x86)\MSBuild\Microsoft\Portable
C:\Program Files (x86)\ReferenceAssemblies\Microsoft\Framework.NETPortable
I later attempted to build a WebApi project targeting .NET Core (this was an xproj file) and as soon as I added the XProj file to my solution, I had to also copy:
C:\Program Files (x86)\MSBuild\Microsoft\VisualStudio\v14.0\DotNet
C:\Program Files (x86)\MSBuild\Microsoft\VisualStudio\v14.0\DotNet.Web
That got me a bit further but it also caused other projects to stop building properly (that were working fine without the XProj file in the solution). One thing I noticed, the NuGet tooling for .NET Core does not support authenticated NuGet feeds, so I had to enable anonymous access on my feed. But now my .NET Standard project now fails with error MSB4057: The target "_GenerateDependencyFragmentJson" does not exist in the project.
I've yet to get around to diagnosing this, but I hope the above information helps someone. If you're not using xproj files and just trying to use .NET Standard projects, the above should be all you need to build without installing Visual Studio.
Just a side note, I tried really hard to avoid having to copy these files by first trying to install Microsoft Build Tools 2015 Update 3, hoping it would put the required files in place, but it did not sadly. I'm pinning my hopes on the next version of MSBuild that is being used in VS15, and hoping that it's build tools package will have everything required to build this stuff when it comes out, as it doesn't seem like they are updating the 2015 Build Tools with this support.
I created a WPF project in VS 2013. After upgrading to VS 2015, this error showed in the designer on types derived from the Blend SDK:
the type from assembly is built with an older version of blend sdk and
is not supported in a windows presentation foundation 4 project
Run Command Prompt as Administrator
Change Directory to Blend SDK: cd C:\Program Files (x86)\Microsoft SDKs\Expression\Blend\.NETFramework\v4.5\Libraries\
Register DLL: gacutil -i System.Windows.Interactivity.dll
Restart Visual Studio
Reference: https://connect.microsoft.com/VisualStudio/feedback/details/755407/xaml-designer-will-not-display-when-using-blend-sdk-behaviors
You can resolve this issue by manually changing the version numbers in .sln and .csproj files.
In .csproj and .csproj.user
change ToolsVersion to your current Visual Studio version. VS 2013 is version 12, VS 2015 is version 14.
In .sln change VisualStudioVersion to the current version, you can find it in the About window.
Also change Microsoft Visual Studio Solution File, Format Version to your current version (eg 14.00, 12.00)
Note: This only works for built-in assemblies. If external dependencies (like Prism) cause this error, you'd have to recompile them using the new Blend SDK. You could also try to update the dependency, maybe the newest version is already compiled using the latest Blend SDK.
None of the other answers here worked for me. What finally solved it was deleting the .NET v4.0 version of the file in the SDK folder:
C:\Program Files (x86)\Microsoft SDKs\Expression\Blend\.NETFramework\v4.0\Libraries\
I am referencing the v4.5 file via NuGet, but it seems that the designer was finding the file in the above folder. The v4.0 file was not registered in the GAC.
The popular answer is valid, but since things are always changing in the developer world, I thought I would note that there's a (IMO) better solution now.
In December 2018, Microsoft released an official, open source, supported NuGet package for XAML behaviors for WPF. (There's a separate one for UWP.) It's very easy to migrate to this package. You need to uninstall your current NuGet package, remove a couple of references, install this package, and change a using statement (or FQN).
https://www.nuget.org/packages/Microsoft.Xaml.Behaviors.Wpf/
https://devblogs.microsoft.com/dotnet/open-sourcing-xaml-behaviors-for-wpf/
I read about it in this SO answer, so credit goes to that OP:
How to add System.Windows.Interactivity to project?
Was having a similar problem using Visual Studio 2017 but none of the answers above fully resolved it for me. Found a Microsoft developer community page that had a workaround that did the trick. Comment by Bran Hagger recommended deleting the .vs folder from the solution's directory. This additional step cleared out the cache and caused Visual Studio to rebuild it.
Just the Microsoft Visual Studio Solution File, Format Version change to 14.00 worked for me.
This also could be that you are mixing different versions of System.Windows.Interactivity.dll, especially if you are getting the SDK from nuget where several different packages provide it, e.g.:
https://www.nuget.org/packages/Expression.Blend.Sdk/
https://www.nuget.org/packages/System.Windows.Interactivity.WPF/
In this case, you'll have to synchronize these libraries among projects.
Deleting the .vs file in the solution folder solved the issue. The issue happened for me after I updated My Visual Studio 2017 and Opened the project that was built before with an older version of Visual studio 2017.
If I create a blank project in VS 2013, I can add DLLs like System.Web.Http or System.Net.Http.Formatting from my local machine. These shipped with (or were automatically updated by) Visual Studio. But the version seems to be 4.0.0.0 even though I have all updates applied. Alternatively, I can get these DLLs from NuGet where the version is 5.2.0.0.
Other than "what the heck is going on?" - I guess my question is, why are my local files out of date if I have all updates applied?
Asp.NET is no deployed by Nuget packages. By default VS have included MVC 4, but MVC 5 is available. That is way your local files were upgraded.
I am trying to solve Dlls reference problem in Visual studio 2012. All dlls have set them self in a way they are looking for .net 4.0 version while I can not install because i have already .Net 4.5 installed with Visual studio 2012.I have asked this Question
but I didnt get a proper answer.Now I am trying to reference System.Core in 4.5 but it can not be referenced as visual studio is not allowing me to do, it says it will be referenced automatically during project build but actually it does not.I am in catch 22 situation.Kindly advise.
I have reinstalled Visual studio 2012 but it didn't help.
Zara, I've looked at the download link you provided and it appears to me it's only for Windows8. Windows7 and Windows8 are very different in how they handle things I personally wouldn't dream of trying to install such an SDK on my Windows7 machine.
My suggestion to you is therefore to try to uninstall the SDK and then it might work again. If this SDK only works for Windows8 then there is no use having it installed on your Windows7 machine. Windows7 is good at keeping backups of all files it replaces when installing SDKs and other things so uninstalling the SDK might restore it to what it was before and it might be just fine after that.
If this doesn't make any difference then I would suggest reinstalling .Net 4.5 AFTER uninstalling the Win8 SDK.