获取当前build的版本信息
获取当前运行程序集的编译时间,觉得很有用,立此为据。
code snippet:
System.IO.FileInfo fileInfo = new System.IO.FileInfo(Assembly.GetExecutingAssembly().Location); this.LabelVersion.CssClass = "VersionString"; this.LabelVersion.Text = "build on " + fileInfo.LastWriteTime.ToString("M/d/yy, HH:mm:ss");