简体   繁体   English

如何编译包含错误的.sln文件?

[英]How to compile a .sln file that contains errors?

I am making a modified version of Smart Steam Emu and it does contain some errors. 我正在制作Smart Steam Emu的修改版,它确实包含一些错误。 I don't have the time and knowledge to fix some of these errors and there are tons. 我没有时间和知识来解决其中的一些错误,而且有很多。 These errors (from what I know) also exist in the stable build. 这些错误(据我所知)也存在于稳定版本中。
I need to test something and I was wondering to compile the project if it contains errors. 我需要测试一些东西,并且我想编译该项目是否包含错误。 Thanks! 谢谢!

IDE: Visual Studio 2013 IDE:Visual Studio 2013
OS: Windows 10 Creators Update 操作系统:Windows 10 Creators Update

As Ken said, you cannot compile the solution without resolving all the errors. 正如Ken所说,您必须先解决所有错误,才能编译解决方案。

That said, there are a couple of ways if you just want to test a particular project, but the errors must be in the project that's not referenced by the project you want to test. 就是说,如果您只想测试一个特定的项目,有两种方法,但是错误必须在您要测试的项目未引用的项目中。

First you need to Set the Project you want to test as Startup project 首先,您需要将要测试的项目设置为启动项目

Method 1: Remove the erroneous project from solution. 方法1:从解决方案中删除错误的项目。 Run the project you want to test. 运行您要测试的项目。

Method 2: Run the solution. 方法2:运行解决方案。 Select “Yes” when VS prompts you with question that you want to continue to run with errors. 当VS提示您要继续运行但出现错误的问题时,请选择“是”。

Hope this is helpful! 希望这会有所帮助!

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

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM