ImageGear for C and C++ on Windows v20.0 - Updated
IG_mpi_is_valid
API Reference Guide > Core Component API Reference > Core Component Functions Reference > Multi Page Image Functions > IG_mpi_is_valid

This function is used for checking whether the hMIGear value is a valid multi-page image handle.

Declaration:

 
Copy Code
AT_BOOL ACCUAPI IG_mpi_is_valid( HMIGEAR hMIGear );

Arguments:

Name Type Description
hMIGear HMIGEAR Handle to allocated multi-page image.

Return Value:

Returns TRUE if the given multi-page image is valid.

Supported Raster Image Formats:

All pixel formats supported by ImageGear for C and C++.

Sample:

MFC Multipage

Example:

 
Copy Code
HMIGEAR hMIGear;       /* handle to multi-page image */
AT_ERRCOUNT             nErrCount = IGE_SUCCESS; /* will hold returned error count */
nErrCount = IG_mpi_create( &hMIGear, 0 );
if ( IG_mpi_is_valid(hMIGear) )
        printf("The multi-page image is valid!");
else
        printf("It's not valid multi-page image!");
IG_mpi_delete( hMIGear );

Remarks:

The multi-page image is valid if the IG_mpi_create() function is returned successfully and IG_mpi_delete() has not been called.

Is this page helpful?
Yes No
Thanks for your feedback.