LoadResource

  HRSRC LoadResource(hModule, hResInfo)    
  HANDLE hModule; /* handle of module containing resource */
  HRSRC hResInfo; /* handle of resource */

The LoadResource function loads the specified resource into global memory.

Parameters

hModule

Identifies the module whose executable file contains the resource. If hModule is NULL, Windows loads the resource from the image file that was used to create the current process.

hResInfo

Identifies the desired resource. This handle is assumed to have been created by using the FindResource or FindResourceEx function.

Return Value

The return value identifies the global memory block that contains the data associated with the resource. It is NULL if no such resource exists.

Comments

It is not necessary to free a resource loaded with LoadResource.

See Also

FindResource, LockResource, LoadLibrary, LoadModule