0 out of 1 rated this helpful - Rate this topic

SizeofResource function

Applies to: desktop apps only

Retrieves the size, in bytes, of the specified resource.

Syntax

DWORD WINAPI SizeofResource(
  __in_opt  HMODULE hModule,
  __in      HRSRC hResInfo
);

Parameters

hModule [in, optional]

Type: HMODULE

A handle to the module whose executable file contains the resource.

hResInfo [in]

Type: HRSRC

A handle to the resource. This handle must be created by using the FindResource or FindResourceEx function.

Return value

Type: DWORD

If the function succeeds, the return value is the number of bytes in the resource.

If the function fails, the return value is zero. To get extended error information, call GetLastError.

Examples

For an example, see Updating Resources.

Requirements

Minimum supported client

Windows 2000 Professional

Minimum supported server

Windows 2000 Server

Header

Winbase.h (include Windows.h)

Library

Kernel32.lib

DLL

Kernel32.dll

See also

Reference
FindResource
FindResourceEx
Conceptual
Resources

 

 

Send comments about this topic to Microsoft

Build date: 2/3/2012

Did you find this helpful?
(1500 characters remaining)
Community Content Add
Annotations FAQ