Hello,
so I made some changes and got the script to work. here is what I did.
-
I removed the “== True” from line 1. it seems since that tag is boolean it does not need to be specified in that way.
-
there was an issue with line2
table = event.source.parent.getComponent('Table')
it was not actually getting any data. so I just directly linked the query tag in.table = system.tag.read("Coating System/Die Command").value
-
I removed the datasetOut line and made a change to the dataOut, to list just the tower.
dataOut = [row['tower'] for row in data if row['pri_tank_command'] > 260]
these changes seem to been doing the trick and I was able to get the correct output when I tested it using the script console. this is the return I got yesterday.
>>> sBody = "please schedule to repalce these Primary Pall filters. " + str(dataOut)
>>> sBody
"please schedule to repalce these Primary Pall filters. [u'376', u'393']"
Thank you everyone for helping me get through this.
Regards.
Gijo