This repository has been archived by the owner on Sep 1, 2023. It is now read-only.
Is it necessary to look at VersionItem.Type before marshalling VS_FIXEDFILEINFO? #53
Dobby233Liu
started this conversation in
General
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
creation date:
2013-01-30T10:39:44.243-08:00
Hi guys,
I'm sad that there hasn't been much activity here recently! This is an awesome project--keep it up!
I have been scouring the web trying to find any implementations of reading a file's version out of its PE header. Everyone "cheats" and uses Win32 calls to pull this resource out. The first example I found that did what I was looking for was here:
http://stackoverflow.com/questions/12396665/c-library-to-read-exe-version-from-linux
Unfortunately, it is not strongly typed and it is in C++. But it was enough to get me started porting it to C#. Of course AFTER I had a working implementation, I ran across this project which does the exact thing I am looking for. As I was investigating your implementation of populating the version information struct (VersionResourceData.RecurseItem), I noticed that the VersionItem.Type is not used to determine if the version resource contains text or binary data, as described in the documentation for the VS_VERSIONINFO.wType:
http://msdn.microsoft.com/en-us/library/windows/desktop/ms647001(v=vs.85).aspx
The C++ code I started with did branch on this property, but I can't figure out if that is necessary or not. Does anyone know the answer to this? Thanks guys!
-Mike
Beta Was this translation helpful? Give feedback.
All reactions