Get Previous Alarm for a Specific Tag
This example checks the last alarm for the tag D2R9R41D3.Simulation0001
with a condition of Simulated
. If the alarm is open, it sets the alarm to return to normal.
Example Code
Set AlarmObj = PreviousAlarmForTag("D2R9R41D3.Simulation00001", "Simulated", "Now")
If Not(AlarmObj Is Nothing) Then
If AlarmObj.EndTime < AlarmObj.StartTime Then
AlarmObj.ReturnToNormal "Now"
End If
End If