在C#控制台应用程序中显示主要/次要版本的最佳方法是什么?在控制台实用程序上应用程序版本的方法应用程序
System.Windows.Forms命名空间包含一个ProductVersion类,可用于显示通过Visual Studio项目属性(Assembly Information)设置的名称/版本信息集。这样,这是我的当前机制:
Console.WriteLine( “{0}({1})”,System.Windows.Forms.Application.ProductName,System.Windows.Forms.Application.ProductVersion) ;
为什么这部分表单?这适用于控制台应用程序吗?
我也是,但看起来像那些方法是坏的位于System.Windows.Forms命名空间,对吧? – 2010-12-10 10:28:49