Version number in .NET Compact Framework application

后端 未结 4 931
陌清茗
陌清茗 2021-02-10 00:39

I need to display the .NET Compact Framework version number on the screen. I am using .NET CF 2.0 with Windows CE 4.0.

So far, I have been ignoring the version numb

4条回答
  •  庸人自扰
    2021-02-10 00:51

    • You can also use Version.ToString() passing the number of components to return as parameter:

      System.Reflection.Assembly.GetExecutingAssembly().GetName().Version.ToString(3)

      This line returns Major.Minor.Build

      Source: http://msdn.microsoft.com/en-us/library/bff8h2e1(VS.80).aspx

    • There is an AssemblyInfo.cs in your project where you can edit your assembly version. To automatically increment the revision you can use something like this: 1.0.3200.*

      Source: http://msdn.microsoft.com/en-us/library/system.reflection.assemblyversionattribute(VS.80).aspx

提交回复
热议问题