Glossary Item Box

ImageMan DLL Suite Version 8 Submit feedback on this topic   

ImgXEndWriteMem

int IMAPI ImgXEndWriteMem (hJob, lpXInfo, phMem, pdwLen)

This function ends an image export to memory. It frees all structures and memory allocated for the write job, except, of course, the memory block containing the in-memory file.

 

Parameter

Type

Description

hJob

HANDLE

Handle identifying this job (from ImgXBeginWrite)

lpXInfo

LPXINFO

Points to an XINFO struct which contains results of the operation.

phMem

HANDLE FAR

 * Points to a HANDLE to receive the value of the memory block containing the exported image.

pdwLen

DWORD FAR

  * Points to a DWORD to receive the size of the exported image.

 

Return Value

The return value is IMGX_OK on success; otherwise it is an ImageMan error code.

Comments

Upon completion of this function, *phMem will contain the handle of the memory block containing the exported image and *pdwLen will contain the size of the exported image. Note that the size of the image is not necessarily the size of the memory block, depending on what was in the block before the image was placed in it.

 

It is your application's responsibility to release the memory block containing the image. Failure to free the memory will result in a memory leak, probably a severe one, in your application.

 

 


Copyright 2008 Data Techniques, Inc. All Rights Reserved