Cloud Templates browser / Active Alarms filter not working

Cloud Templates browser / Alarms / Active Alarms:

The “TagPath” filter of Active Alarms template is not working. I tried to add another filter “displaypath” and didn’t succeed.

The existing expression for Alarms counter is:

runScript(“len(system.alarm.queryStatus(path=[’”+
{Active Alarms.TagPath}+
“*’],state=[”+
if({Active Alarms.ActiveAndAcked},"‘ActiveAcked’,","")+
if({Active Alarms.ActiveAndUnacked},"‘ActiveUnacked’,","")+
if({Active Alarms.ClearAndAcked},"‘ClearAcked’,","")+
if({Active Alarms.ClearAndUnacked},"‘ClearUnacked’,","")+
“]))”,1000)

Pls provide the right expression to query with either TgaPath or displaypath. Thanks.

I am sorry. It works very well now. The problem was with missing wild card * character.

I have added “DisplayPath” filter also and checked. Works perfectly. Still i am checking and will inform any malfunction if it happens. Thanks.

Corrected Code with “TagPath” filter:

runScript(“len(system.alarm.queryStatus(path=[’”+
’+
{Active Alarms2.TagPath}+
"
’],state=["+
if({Active Alarms2.ActiveAndAcked},"‘ActiveAcked’,","")+
if({Active Alarms2.ActiveAndUnacked},"‘ActiveUnacked’,","")+
if({Active Alarms2.ClearAndAcked},"‘ClearAcked’,","")+
if({Active Alarms2.ClearAndUnacked},"‘ClearUnacked’,","")+
“]))”,1000)

Corrected Code with “DisplayPath” filter:

runScript(“len(system.alarm.queryStatus(path=[’”+
’+
{Active Alarms.DisplayPath}+
"
’],state=["+
if({Active Alarms.ActiveAndAcked},"‘ActiveAcked’,","")+
if({Active Alarms.ActiveAndUnacked},"‘ActiveUnacked’,","")+
if({Active Alarms.ClearAndAcked},"‘ClearAcked’,","")+
if({Active Alarms.ClearAndUnacked},"‘ClearUnacked’,","")+
“]))”,1000)