28.12.2021, 08:33
You can create a custom function and place it into Common functions. Then this function can be used in all script.
Event script:
Code:
function mailalert(subject, message)
mail({ ... }, subject, message)
alert(message)
end
Event script:
Code:
temperature = event.getvalue()
subject = 'Vestis Gerby Alarm'
message = 'Vestis Gerby Alarm ' .. temperature
mailalert(subject, message)