viUninstallHandler
Syntax
viUninstallHandler(ViSession vi, ViEventType eventType, ViHndlr handler, ViAddr userHandle);
Description
This function allows applications to uninstall handlers for events on sessions. Applications should also specify the value in the userHandle parameter that was passed to viInstallHandler while installing the handler. VISA identifies handlers uniquely using the handler reference and the userHandle. All the handlers or which the handler reference and the userHandle matches are uninstalled.
Parameters
Name |
Dir |
Type |
Description |
---|---|---|---|
vi |
IN |
ViSession |
Unique logical identifier to a session. |
eventType |
IN |
ViEventType |
Logical event identifier. |
handler |
IN |
ViHndlr |
Interpreted as a valid reference to a handler to be uninstalled by an application. (See the following table.) |
userHandle |
IN |
ViAddr |
A value specified by an application that can be used for identifying handlers uniquely in a session for an event. |
The following events are valid: |
|||
Event Name |
|
|
Description |
VI_EVENT_IO_COMPLETION |
|
|
Notification that an asynchronous operation has completed. |
VI_EVENT_PXI_INTR |
|
|
Notification that a vendor-specific PXI interrupt was received from the device. |
VI_EVENT_SERVICE_REQ |
|
|
Notification that a device is requesting service. |
VI_EVENT_TRIG |
|
|
Notification that a hardware trigger was received from a device. |
VI_EVENT_VXI_SIGP |
|
|
Notification that a VXI signal or VXI interrupt has been received from a device. |
Special Value for handler Parameter |
|||
Value |
|
|
Action Description |
VI_ANY_HNDLR |
|
|
Uninstall all the handlers with the matching value in the UserHandle parameter. |
Return Values
Type ViStatus |
This is the function return status. It returns either a completion code or an error code as follows. |
Completion Code |
Description |
---|---|
VI_SUCCESS |
Event handler successfully uninstalled. |
Error Code |
Description |
VI_ERROR_HNDLR_NINSTALLED |
A handler is not currently installed for the specified event. |
VI_ERROR_INV_EVENT |
Specified event type is not supported by the resource. |
VI_ERROR_INV_HNDLR_REF |
Either the specified handler reference or the user context value (or both) does not match any installed handler. |
VI_ERROR_INV_SESSION |
The given session or object reference is invalid (both are the same value). |
See Also
See the handler prototype viEventHandler for its parameter description.
See the viEnableEvent description for information about enabling different event handling mechanisms. See individual event descriptions for context definitions.