Show/Hide Toolbars

XSharp

 

使用 -usenativeversion 编译器选项,编译器将使用 Win32 资源文件中提供的本地 Win32 版本资源,而不会从程序集属性中生成资源。

语法

-usenativeversion  

备注

托管资源通常由代码生成,例如下面的代码:

[assembly: AssemblyTitleAttribute( "Mycompany Custom Controls" )]
[assembly: AssemblyDescriptionAttribute( "This is a description of the assembly" )]
#ifdef __DEBUG__
[assembly: AssemblyConfigurationAttribute( "Debug" )]
#else
[assembly: AssemblyConfigurationAttribute( "Release" )]
#endif
[assembly: AssemblyCompanyAttribute( "MyCompanyName" )]
[assembly: AssemblyProductAttribute( "MyProductName" )]
[assembly: AssemblyCopyrightAttribute( "Copyright © 2020 MyCompanyName" )]
[assembly: AssemblyTrademarkAttribute( "TM MyCompanyName" )]
[assembly: AssemblyCultureAttribute( "en-US" )]
// Version information for an assembly consists of the following four values:
[assembly: AssemblyVersionAttribute( "2.3.1" )]
[assembly: AssemblyFileVersionAttribute( "2.3.1" )]
[assembly: AssemblyInformationalVersionAttribute( "2.3.1 Special Build for customer Contoso" )]

 

我们使用此类属性在运行时程序集中生成版本信息:

 

versioninfo

 

 

查看属性页