If this code is explicitly specified in the MVC project (and not in the auxiliary assembly), you should be able to use System.Reflection.Assembly.GetExecutingAssembly().GetName().Version.ToString(3) , which returns the major, minor, and revision numbers . Otherwise, you can use something like typeof(HomeController).Assembly.GetName().Version.ToString(3) .
source share