DTWAIN_GetDeviceNotifications |
Top Previous Next |
The DTWAIN_GetDeviceNotifications function gets the device events that the application is allowed to capture.
DTWAIN_BOOL DTWAIN_GetDeviceNotifications (
Parameters Source An open TWAIN Source.
lpDeviceValues Address of LONG to store the current device events to capture.
Return Values The return value is TRUE if successful. Otherwise FALSE is returned.
Comments The DTWAIN_GetDeviceNotifications function gets the device events that will be sent by the Source. The Source Source must be selected using one of the Source Selection Functions. Calling DTWAIN_SetDeviceNotifications sets up device notifications. By default, no device events are set up for capture.
The lpDeviceEvents address points to a LONG that will be filled in with the device events that the Source will capture. To interpret the LONG value, the device events are specified as bits within the value. A bit-wise AND with the LONG at address lpDeviceEvents and one of the constants defined in DTWAIN below can determine if the Source has been set up to capture the device event
The DTWAIN_IsCapSupported function can be used to test if device events are supported by the Source. The capability, DTWAIN_CV_CAPDEVICEEVENT is used as the cap to test. Even though DTWAIN always checks if the capability is supported when the DTWAIN_GetDeviceNotifications function is called, an application will be able to determine itself whether a Source can perform device events.
For more information on device events, see the topic Capturing Source Device Events.
TWAIN State Transitions The Source must be in State 4. or higher
Prerequisite Function Call(s)
DTWAIN Source Selection Function
See Also |