using automated VC build number to show build date in window title

This commit is contained in:
hbeham
2017-10-29 16:11:00 +01:00
parent aa4e0a93e0
commit f6e039a08d
2 changed files with 6 additions and 3 deletions

View File

@@ -31,7 +31,7 @@ namespace ChanSort.Ui
{
public partial class MainForm : XtraForm
{
public const string AppVersion = "v2017-10-29";
public static string AppVersion { get; private set; }
private const int MaxMruEntries = 10;
private readonly List<string> isoEncodings = new List<string>();
@@ -60,6 +60,9 @@ namespace ChanSort.Ui
this.LookAndFeel.SetSkinStyle("Office 2010 Blue");
InitializeComponent();
var version = this.GetType().Assembly.GetName().Version;
AppVersion = new DateTime(2000, 1, 1).AddDays(version.Build).ToString("yyyy-MM-dd");
// remember which columns should be visible by default
foreach (GridColumn col in this.gviewLeft.Columns)
col.Tag = col.Visible;

View File

@@ -34,5 +34,5 @@ using System.Runtime.InteropServices;
// You can specify all the values or you can default the Build and Revision Numbers
// by using the '*' as shown below:
// [assembly: AssemblyVersion("1.0.*")]
[assembly: AssemblyVersion("1.0.0.0")]
[assembly: AssemblyFileVersion("1.0.0.0")]
[assembly: AssemblyVersion("1.0.*")]
//[assembly: AssemblyFileVersion("1.0.0.0")]