Error Messages

I have created a Communication heart beat between an Ignition application and an Allean Brandly PLC.
I have the Ignition application writing to the PLC every 5 seconds using a “Tag Change” on a Client Event Script.
However if the application fails to write to the PLC an Error box appears indicating – “Error writing to tag”. When the communication has re-established this Error message is still displayed. Is it possible to configure Ignition to automatically close the Error message when the issue is resolved.


At first blush, I’d say probably not. Others will be sure to chime in if I’m wrong. :slight_smile:

But if you can set up the heartbeat to be driven by PLC, you can use an alarm in ignition that can, in turn, drive whatever you want to display.

You could search for the name of the error message window(see if it’s open) and close it with system.nav.closeWindow.

There might be a solution using swing’s object hierarchy to find that window, but the right answer is to not allow the error to occur in the first place. Where you are calling system.tag.write() for this, wrap it in a try: … except: block. When the error occurs, you’ll be able to script a controlled response.
Also, you say that this is a client event script. You’re going to have much misery once you try to run multiple clients, or you have a designer open in preview at the same time as the client. Heartbeats are functions that need to run at a single, reliable point. In Ignition, that’s the gateway.