简体   繁体   English

项目需要哪个版本的.NET Framework?

[英]Which version of .NET Framework will be required for project?

I have two projects in my solution, eg Project1 and Project2. 我的解决方案中有两个项目,例如Project1和Project2。 Project1 targets .NET Framework 2.0, and Project2 targets .NET Framework 3.5. Project1以.NET Framework 2.0为目标,而Project2以.NET Framework 3.5为目标。 Project1 has no references to Project2, the purpose of Project2 is to use the .exe file it generates in post-build of Project1. Project1没有对Project2的引用,Project2的目的是使用它在Project1的后期构建中生成的.exe文件。 However, when I try to run Project1.exe on a machine with .NET Framework 2.0 it says that it needs .NET 3.5 to run. 但是,当我尝试在具有.NET Framework 2.0的计算机上运行Project1.exe时,它表示它需要运行.NET 3.5。 Is is because Project2 is in the same solution as Project1? 是因为Project2与Project1在同一个解决方案中吗? If it is, are there any ways of resolving this apart form changing the target framework for Project2? 如果是,有没有办法解决这个问题,改变Project2的目标框架? Thanks! 谢谢!

If your project1 uses exe build in project2 which is targeted to .net 3.5 its simple that 3.5 is needed 如果你的project1使用了针对.net 3.5的project2中的exe build,那么简单就需要3.5

if You want to change target for Project2 check this link: Click Here 如果要更改Project2的目标,请选中此链接: 单击此处

也许你在project1里面使用了一个需要.net 3.5的库?

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

相关问题 将.NET Core项目发布到Nuget - 要使用哪个框架版本? - Publishing a .NET Core project to Nuget - which framework version to use? ClickOnce:此计算机上未安装所需的.NET Framework版本 - ClickOnce: The required version of the .NET Framework is not installed on this computer 测试 .NET 框架项目所需的最少工具 - Minimal tooling required to test a .NET Framework project 我的项目中安装了哪个版本的Entity Framework? - Which version of Entity Framework is installed in my project? 我可以在版本4.6.2的Visual Studio项目中使用针对4.5.1 .net框架的库吗? - Can I use a library which is targeted to 4.5.1 .net framework in a visual studio project of version 4.6.2 库将在哪个.net框架版本中运行 - Which .net framework version will a library run in 如何确定运行我的应用程序所需的最小.NET框架版本 - How to determine the minimal required .NET framework version to run my app System.Net.Http 的 .NET Framework 版本高于 Project - Higher .NET Framework Version for System.Net.Http than Project 其中.Net Framework版本C#7.2可用 - In Which .Net Framework Version C# 7.2 is Available 将.NET Framework版本4.5.1定位到通用Windows 10的项目 - Project targeting .NET Framework version 4.5.1 to Universal Windows 10
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM