GetFileVersionInfoSizeEx function
Determines whether the operating system can retrieve version information for a specified file. If version information is available, GetFileVersionInfoSizeEx returns the size, in bytes, of that information.
Syntax
DWORD WINAPI GetFileVersionInfoSizeEx( _In_ DWORD dwFlags, _In_ LPCTSTR lptstrFilename, _Out_ LPDWORD lpdwHandle );
Parameters
- dwFlags [in]
-
Type: DWORD
Controls which MUI DLLs (if any) from which the version resource is extracted. Zero or more of the following flags.
- lptstrFilename [in]
-
Type: LPCTSTR
The name of the file of interest. The function uses the search sequence specified by the LoadLibrary function.
- lpdwHandle [out]
-
Type: LPDWORD
When this function returns, contains a pointer to a variable that is set to zero because this function sets it to zero. This parameter exists for historical reasons.
Return value
Type: DWORD
If the function succeeds, the return value is the size, in bytes, of the file's version information.
If the function fails, the return value is zero. To get extended error information, call GetLastError.
Remarks
Call the GetFileVersionInfoSizeEx function before calling the GetFileVersionInfoEx function. The size returned by GetFileVersionInfoSizeEx indicates the buffer size required for the version information returned by GetFileVersionInfoEx.
Requirements
|
Minimum supported client |
Windows Vista [desktop apps only] |
|---|---|
|
Minimum supported server |
Windows Server 2008 [desktop apps only] |
|
Header |
|
|
Library |
|
|
DLL |
|
|
Unicode and ANSI names |
GetFileVersionInfoSizeExW (Unicode) and GetFileVersionInfoSizeExA (ANSI) |
See also
- Reference
- GetFileVersionInfoSize
- GetFileVersionInfoEx
- VS_VERSIONINFO
- VerQueryValue
- Conceptual
- Version Information