ImageGear for C and C++ on Windows v19.4 - Updated
IG_TWAIN_source_close
API Reference Guide > TWAIN Component API Reference > TWAIN Component Functions Reference > Source Functions > IG_TWAIN_source_close

This function closes the currently opened Data Source.

Declaration:

 
Copy Code
AT_ERRCOUNT ACCUAPI IG_TWAIN_source_close()

Arguments:

None

Return Value:

Returns the number of ImageGear errors that occurred during this function call. If there are no errors, the return value is IGE_SUCCESS.

Supported Raster Image Formats:

This function does not process image pixels.

Remarks:

When an application is finished with a Data Source, it must formally close the session between them using this function. This is necessary in case the Data Source only supports connection with a single application (many desktop scanners will behave this way). A Data Source such as this cannot be accessed by other applications until its current session is terminated.