Is there a way to determine which errors are reported by Email? I can get it to email on certain errors but not others; specifically, it seems like only ML.STAR errors step errors are reported, whereas code related errors (e.g., left hand side not a number and such) are not.
The send email on error feature enabled in system configuration editor is designed to only send automatic emails when waiting error dialogs are produced on ML_STAR and other device steps configured as a deck instrument.
To have Run Control send emails on other occurrences, you can use the âSend Emailâ function of the HSLUtilLib library, which is default to all VENUS installations. The function is straightforward, only needing string variables/values as parameters for recipient address, subject and body.
This function is configured to use the same sender and SMTP settings that you already have specified in configuration editor used to send emails on error, unless you use functions within the library to temporarily overwrite those settings.
This function can be called programmatically whenever you want, whether in error handling situations or OnAbort.
For sending emails with the intent to capture programmatic errors or bugs, I recommend using the function âErrGetDescriptionâ of the HSLErrLib library (also default) prior to the SendEmail function. This command will return a string whose value will contain a description of whatever the active/current error object is. This can be used as the body of the email to capture details.
Quick question regarding this. In the âtoâ parameter, is there a way to list multiple email addresses? Or will this only work with one email?
Same question applies to email address setting in the system configuration settings.
I ask since our SMTP will work fine with single email address, but our internal SMTP system wonât work with email distribution lists.
If not, itâs not the end of the world, as I can get around this by setting up some outlook filtering rules to automatically forward the emails to the relevant other people as necessary.
Not for the default error handling emails (the one you set in system config). Youâd have to deal with the sending of emails yourself if you wanted to split on a delimiter.
I could never find a way to designate multiple emails, so weâve gone with a distribution list.