2010年5月3日 星期一

[.NET]How to get file version with .NET

If you want to get file version in AssemblyInfo file.
You must use this code.

string version =
FileVersionInfo.GetVersionInfo(Assembly.GetExecutingAssembly().Location).FileVersion.ToString();

this code must using these namespace.

using System.Reflection;
using System.Diagnostics;

沒有留言:

張貼留言

Hello