AdvancedHMI Software

General Category => Support Questions => Topic started by: qwideman on June 12, 2014, 09:51:17 AM

Title: Execute code when Ethernet TCP/IP connection closed
Post by: qwideman on June 12, 2014, 09:51:17 AM
I'd like to run a subroutine whenever my PLC connection causes an error. I'm using Modbus TCP/IP.

I have tried:
 
Sub Comm_error(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles ModbusTcpCom.ComError
Msgbox...etc
End Sub

This does not execute, even if I set ModbusTcpComm to an address other than my PLC.


How should I be doing this?

Quinton
Rolan Inc.