Jaiiyer Posted February 14, 2024 Report Posted February 14, 2024 Hi, is it possible to close the sysmac studio popup window automatically without the press of any button? basically after the pop up window is opened for certain amount of time the window closes by itself. Quote
photovoltaic Posted February 14, 2024 Report Posted February 14, 2024 Yes, with VB script. There are a few ways but I would personally run a Global subroutine every second, in that subroutine you establish a time (in seconds) at which you force a screen change. In this example if the popup is the current page the script will force a screen change to "Main" after 270 seconds: Sub popTimer If _HMI_CurrentPage = "Popup" Then accum = accum+1 If accum >270 Then _HMI_CurrentPage = "Main" End If Else accum = 0 End If End Sub 1 Quote
Jaiiyer Posted February 14, 2024 Author Report Posted February 14, 2024 I found a way to do it. Set a variable when the page is open (lets call it PAGEOPEN). Use global events to monitor PAGEOPEN and a onesecpulse variable from PLC(i used Get1sClk block) and increment a local variable. And when the local variable goes beyond certain number you can close the page it in global events and reset the variable Quote
Jaiiyer Posted February 14, 2024 Author Report Posted February 14, 2024 Thanks @photovoltaic.. Yup i kinda did the same.. 1 Quote
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.