title: Version my code when published in to production or testing
body: <pre><code>public class AV
  {
      System.Version version = System.Reflection.Assembly.GetExecutingAssembly().GetName().Version;
  
      public string currentVersion()
      {
          string VersionLabel = "Version: " + version.Major + "." + version.Minor + " " + BuildDate().ToShortDateString();
          return VersionLabel;
      }
  
      public DateTime BuildDate()
      {
          try
          {
              DateTime date = Convert.ToDateTime("8/1/2017");
              System.Version version = System.Reflection.Assembly.GetExecutingAssembly().GetName().Version;
              date = date.AddDays(version.Build);
              date = date.AddSeconds(version.Revision * 2);
              if (TimeZone.IsDaylightSavingTime(System.DateTime.Now, TimeZone.CurrentTimeZone.GetDaylightChanges(System.DateTime.Now.Year)))
              {
                  date = date.AddHours(1);
              }
              return date;
          }
          catch (Exception ex)
          {
              return DateTime.Now;
          }
      }
  }
  </code></pre>
  
  <p>I'm using this model class in HTML and calling current version </p>
  
  <p>Right now its just displaying just date how many times I publish. Its not getting the build date. Should I need to able to enable something in visual studio or need to add something?</p>
  
  <p>Thanks. </p>