User`s guide
Programming with VISA 3
Agilent VISA User’s Guide 57
Using Events and Handlers
This section provides guidelines to using events and
handlers, including:
• Events and Attributes
• Using the Callback Method
• Using the Queuing Method
Events and Attributes
Events are special occurrences that require attention from
your application. Event types include Service Requests
(SRQs), interrupts, and hardware triggers. Events will not be
delivered unless the appropriate events are enabled.
Event Notification
There are two ways you can receive notification that an
event has occurred:
• Install an event handler with viInstallHandler, and enable
one or several events with viEnableEvent. If the event
was enabled with a handler, the specified event handler
will be called when the specified event occurs. This is
called a callback.
NOTE
VISA cannot call back to a Visual Basic function. Thus, you can only use
the queuing mechanism in viEnableEvent. There is no way to install a
VISA event handler in Visual Basic.
NOTE
VISA cannot call back to a Visual Basic function. This means that you can
only use the VI_QUEUE mechanism in viEnableEvent. There is no way to
install a VISA event handler in Visual Basic.