You should all have noticed if you right click a file in the windows explorer, there is a tab named Details. Is there any trick to get these properties, and specifically the product name, whether this is a .NET file or not, over C#?
Thank you.
You should all have noticed if you right click a file in the windows explorer, there is a tab named Details. Is there any trick to get these properties, and specifically the product name, whether this is a .NET file or not, over C#?
Thank you.
You can use the FileVersionInfo
class for that purpose.
FileVersionInfo fvi = FileVersionInfo.GetVersionInfo(fileName);
Console.WriteLine("Product name : {0}", fvi.ProductName);