开发者

Accessing c++ com object (version info) from .Net

开发者 https://www.devze.com 2023-02-09 15:30 出处:网络
I have a .Net project where we access COM objects written in C++. In my About box (in the .Net part) I wish to display the version of the used COM objects.

I have a .Net project where we access COM objects written in C++.

In my About box (in the .Net part) I wish to display the version of the used COM objects.

I currently have version info on the COM objects (visible in Windows Explorer->Properties->Version).

How can I read the version (and preferably Copyright ec开发者_运维技巧t) from C# code?

Thanks for any input,

Anders, Denmark


  FileVersionInfo fileVersion = FileVersionInfo.GetVersionInfo(path);
  string version = string.Format("Version {0}",fileVersion.FileVersion);
0

精彩评论

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