JS Error Message for returning to main window
September 11, 2020 12:00 AM
Hi Everyone,
I’m using L18 desktop version and I’ve a video playing in a pop-up window and I’m trying to return to the main screen after it’s done playing. I’m using these actions on the video:
On Done Playing: Exit/Close Window
On Hide: RunJS: opener. runGroup_og139946();
But when I preview it, I get the attached message. I’ve used this method before and it worked fine, but I don’t know why it is not working any more. I tested it in Chrome and Edge with no luck. Did I do something wrong?
Discussion (5)
Hi Therese (@tmichael9734)
Is it possible to post a simple example title here?
Thanks,
Joe
Hi Therese (@tmichael9734)
Here is another alternative:
Create a variable, say, ReturnToPage and create it so it is initially false.
Then on the main page add a Timed Interval action that would Run the Action Group when the condition ReturnToPage is equal to true. Setting that to run every 1 seconds should work fine.
Then you could have these actions on your video:
On Done Playing: Modify Variable Set ReturnToPage equal to true
On Done Playing: Exit/Close Window
And in the Action Group that gets run put this action at the beginning (so the Action Group isn't run again):
Modify Variable Set ReturnToPage equal to false
For other pages where you have this similar situation you should be able to reuse that same variable.
Hope this helps!
Joe
Maybe there is no "opener" any more if you close the window before the group is run. You could try to run the group first.
I'm so sorry Joe and Tim, I just saw your responses now. I don't know why I didn't get the notification.
Thank you so much, I'll go through them and will come back to you.
undefined
Hi Joe again,
Yes, it worked!!! Many many thanks!
Discussions have been disabled for this post