Go Premium for a chance to win a PS4. Enter to Win

x
?
Solved

Extracting a file version

Posted on 1998-08-03
2
Medium Priority
?
283 Views
Last Modified: 2013-11-19
I have a DLL that contains its own About box.  I would like that box to display its current version, based on the value I enter into the VS_VERSION resource.  How can I extract that information?  Furthermore, how can I extract the filename of the DLL when it is running, instead of hard-coding the name?
0
Comment
Question by:DenMan
2 Comments
 
LVL 15

Accepted Solution

by:
Tommy Hui earned 80 total points
ID: 1320178
To extract any resource, you can use LoadResource() to get a pointer to the information. Then you can use pointer arithmetic and parsing to get at the correct information. Alternatively, you can use VerQueryFileEx() to get the information.

To extract any module name, you can use GetModuleFileName() and pass the HINSTANCE of the DLL.
0
 

Author Comment

by:DenMan
ID: 1320179
I am using MS Visual C++ 5.0--I couldn't find any reference to VerQueryFileEx() in the online help.  Where can I find more information on that function?
0

Featured Post

New feature and membership benefit!

New feature! Upgrade and increase expert visibility of your issues with Priority Questions.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Introduction: Hints for the grid button.  Nested classes, templated collections.  Squash that darned bug! Continuing from the sixth article about sudoku.   Open the project in visual studio. First we will finish with the SUD_SETVALUE messa…
If you use Adobe Reader X it is possible you can't open OLE PDF documents in the standard. The reason is the 'save box mode' in adobe reader X. Many people think the protected Mode of adobe reader x is only to stop the write access. But this fe…
This video will show you how to get GIT to work in Eclipse.   It will walk you through how to install the EGit plugin in eclipse and how to checkout an existing repository.
This lesson discusses how to use a Mainform + Subforms in Microsoft Access to find and enter data for payments on orders. The sample data comes from a custom shop that builds and sells movable storage structures that are delivered to your property. …
Suggested Courses

886 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question