哪里是"设为启动"定义和C#的WinForms解决方案持续? [英] Where is "Set as Startup" defined and persisted in C# winforms solutions?

查看:105
本文介绍了哪里是"设为启动"定义和C#的WinForms解决方案持续?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我没有看到它在.sln文件,这是我所期待的。

I don't see it in the .sln file, which is what I expected.

推荐答案

哪些项目是启动项目不仅具有任何用于调试的相关性,这意味着它从溶液中和项目点用户的元数据。无论哪个项目是启动项目,编译后的代码是一样的。

Which project is the "startup" project only has any relevance for debugging, which means it's user metadata from the point of the solution and the projects. Regardless of which project is the "startup" project, the compiled code is the same.

由于此,信息被存储为在伴随解文件(solution.sln)的解决方案用户选项文件(solution.suo)的用户设置。根据的 MSDN

Because of this, the information is stored as a user setting in the Solution User Options file (solution.suo) which accompanies the Solution file (solution.sln). The .suo file "Records all of the options that you might associate with your solution so that each time you open it, it includes customizations that you have made" according to MSDN.

该文件名为.suo是一个二进制文件。如果你想阅读或编程方式改变它,你必须使用 IVsPersistSolutionOpts.LoadUserOptions Microsoft.VisualStudio.Shell.Interop 命名空间。

The .suo file is a binary file. If you want to read or change it programatically, you have to use IVsPersistSolutionOpts.LoadUserOptions from the Microsoft.VisualStudio.Shell.Interop namespace.

这篇关于哪里是"设为启动"定义和C#的WinForms解决方案持续?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
相关文章
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆