i wanna open a popup when the value of electrical tension is bigger then 15050.
when i put this code system.perspective.openPopup(12344,'SobreTensaoEntrada') inside an event click on button, works perfectly. but i don wanna this. he needs open automatically
Mildly related, how would you handle if the value kept oscillating above and below the setpoint, and you wanted prevent the popup from re-opening itself if it was already present?
You should know that if you add a custom property to that view, the binding and therefore the script will only execute when that particular view is open. If you want it to happen regardless of the screen the user has opened, consider adding a Session custom property
See how these two last lines have different indentations? This means that your script will always fire even if tagValue2 isn't bigger than 15050
If you want to make things more elaborate for your final paper, think about what should happen if the user just closes the popup. The value will remain above 15050 and there won't be any popups to alert the user of that condition.