![]() |
(SST) ShlWAPIFunctionInfo Version 1.0 |
---|---|
Developer Reference |
Retrieves the VS_FIXEDFILEINFO data record/structure from the in-memory copy of the version information resources of an executable. |
Scope |
---|
Protected (i.e. the method can only be accessed from code in a descendant class or the unit it which it is implemented). |
Syntax | |
---|---|
Function RetResourceFixedFileInfo() : TVSFixedFileInfo; VIRTUAL; |
Parameters | |
---|---|
None |
Return Values |
---|
If the function succeeds it returns a copy of the VS_FIXEDFILEINFO data record/structure in the version information of the file. If the function fails it returns an empty recourd (i.e. all members/fields arer set to zero (0)). |
Remarks | ||||||
---|---|---|---|---|---|---|
The returned data is also available in form of property ResourceFixedFileInfo, and reading the property should be preferred to calling the RetResourceFixedFileInfo function directly. | ||||||
The function reads property ResourceVersionInfo to obtain a pointer to the in-memory copy of the version information. Provided the pointer is not nil, the function then calls the ANSI version of the Windows API function VerQueryValue to obtain a pointer to the VS_FIXEDFILEINFO record. If VerQueryValue returns TRUE and the values returned via the parameters ane valid (i.e. non-nil and larger zero), the data from the in-memory copy of the VS_FIXEDFILEINFO record/structure is copied into the returned record/structure and the function exits. If VerQueryValue returns FALSE or either of the two values returned in the parameters are invalid, the function calls procedure SetLastErrorCode with a default error code of -1 (0xFFFFFFFF). | ||||||
As the function always returns a TVSFixedFileInfo record/structure, it is not possible to establish whether the call succeeded or not, based solely on the return value. However, it is possible to determine failure or success indirectly by any, or a combination of, the three following methods.
|
||||||
TVSFixedFileInfo is the Delphi SDK synonym for VS_FIXEDFILEINFO. |
Requirements | |
---|---|
Unit | (Declared and implemented in) SSTNewUnit.pas |
Library | SSTNewUnit.dcu/SSTNewUnit.obj |
Unicode | Implemented as ANSI version only. |
Document/Contents version 1.00 Page/URI last updated on April 28, 2022 |
Copyright © Stoelzel Software Technologie (SST) 2010 - 2017 |
Suggestions and comments mail to: webmaster@stoelzelsoftwaretech.com |