Instrument Control (GPIB, Serial, VISA, IVI)

cancel
Showing results for 
Search instead for 
Did you mean: 

OnError function not executing properly

We have connected a Function Generator to PC through GPIB port using NI make PCI-GPIB card. Also  we have connected Power Meter to PC through Ethernet using NI make GPIB/ENET-100. One more Serial Port device is connected to serial port of the PC. We have developed our own application in VC++ where we are acquiring data from Function Generator, Power Meter and serial port device. We have used CWGPIB1 and CWSERIAL1 ActiveX Control for communicating with the devices. The application is working fine i.e we are able to send query to all the devices and get back the response. But when any one of the device is OFF the error message is issued as Exceptiononerror= TRUE . But when we wrote the code in function for OnError for Function Generator which is connected through PCI-GPIB card that code is working fine i.e application is executing the code written in OnError function, but the code written in function OnError for Power Meter which is connected through GPIB/ENET-100 and serial port device dose not execute and the application gets hanged and we have to terminate the application. We have set Exceptiononerror= FALSE for all the devices.
 
 
0 Kudos
Message 1 of 1
(3,199 Views)