Export (0) Print
Expand All
6 out of 13 rated this helpful - Rate this topic

GetFileVersionInfoSize function

Determines whether the operating system can retrieve version information for a specified file. If version information is available, GetFileVersionInfoSize returns the size, in bytes, of that information.

Syntax


DWORD WINAPI GetFileVersionInfoSize(
  _In_       LPCTSTR lptstrFilename,
  _Out_opt_  LPDWORD lpdwHandle
);

Parameters

lptstrFilename [in]

Type: LPCTSTR

The name of the file of interest. The function uses the search sequence specified by the LoadLibrary function.

lpdwHandle [out, optional]

Type: LPDWORD

A pointer to a variable that the function sets to zero.

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 GetFileVersionInfoSize function before calling the GetFileVersionInfo function. The size returned by GetFileVersionInfoSize indicates the buffer size required for the version information returned by GetFileVersionInfo.

Requirements

Minimum supported client

Windows 2000 Professional [desktop apps only]

Minimum supported server

Windows 2000 Server [desktop apps only]

Header

Winver.h (include Windows.h)

Library

Version.lib

DLL

Version.dll

Unicode and ANSI names

GetFileVersionInfoSizeW (Unicode) and GetFileVersionInfoSizeA (ANSI)

See also

Reference
GetFileVersionInfo
VS_VERSIONINFO
VerQueryValue
Conceptual
Version Information

 

 

Did you find this helpful?
(1500 characters remaining)
Thank you for your feedback

Community Additions

ADD
Show:
© 2014 Microsoft. All rights reserved.