开发者

How to get the properties of the Details tab in a file

开发者 https://www.devze.com 2022-12-16 22:41 出处:网络
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 n

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#?


You can use the FileVersionInfo class for that purpose.

FileVersionInfo fvi = FileVersionInfo.GetVersionInfo(fileName);
Console.WriteLine("Product name : {0}", fvi.ProductName);
0

精彩评论

暂无评论...
验证码 换一张
取 消

关注公众号