Hi,
I am trying to separate critical priority alarms from others,
I have written a small script on a button which runs on click.
the code is:-
`alarms = system.alarm.queryStatus(priority=3,state=[“ActiveUnacked”])
event.source.parent.getComponent(‘alarm_test’).data = alarms.getDataset()
alarm_data = event.source.parent.getComponent(‘alarm_test’).data
i = 0
for row in range(alarm_data.rowCount):
i = i + 1
event.source.text = str(i) + “Alarms”
event.source.number = i
try:
window = system.gui.getWindow(“Main Windows/Alarm status”)
system.nav.closeWindow(window)
except:
system.nav.openWindow(“Main Windows/Alarm status”)`
But the code shows all alarm.
What may be the issue?