Java Script Error with Video

I've a video that pops up in a separate window and when done playing the window closes and the user returns to the main training. One of the users complained that the video pauses in the middle and the below error message appears and when she clicks Ok, she gets kicked out of the training.

Is there any explanation for this JS error?

Thank you,

Discussion (13)

@tmichael9734 When you did the workaround suggested in the other thread, did the error message from your original post in this thread go away? Do you have an action running when the video stops playing?

Can you upload the course here? If necessary, you can remove all the contents except the page that launches the video (and the video, of course). What version of Lectora do you have? What browser is your user using? Has she tried "Safe mode" (which turns off all plugins)?

Actually the video is running fine at my end and I tested it online in 3 browsers: IE, Chrome and Edge. It also works fine on LMS. The issue only appeared at the client's side when she played it on her browser. She said that she tested it in the same three browsers and every time the video ends, she received the above error and she's kicked out of the training.

@carlfink, thank you for your response. I'm sorry, I cannot upload any files or videos, but I'll help with answering your questions. The title is built in L19, and the user tried to run it on IE, Chrome and Edge; however the issue persists in the three of them. I'm not sure which mode she was in when she took the training.

What does the error message mean?

Thank you again.

Tim's right, though: the message actually says "OnShowRunJS". If you don't have any such action, your AWT has become corrupted.

@carlfink thank you, but that's so sad. Do I have to redo the entire title?

@timk thanks a lot. Actually the I followed Joe's steps here https://rockstars.elearningbrothers.com/discussion/450519/js-error-message-for-returning-to-main-window#latest to force the user to go back to the main screen. There was no Javascripts involved.

The error seems to be caused by an "On: Show - Run javascript" action. It may depend on the code in that action. The error basically means that jQuery is not available.

Actually the video is running fine at my end and I tested it online in 3 browsers: IE, Chrome and Edge. It also works fine on LMS. The issue only appeared at the client's side when she played it on her browser. She said that she tested it in the same three browsers and every time the video ends, she received the above error and she's kicked out of the training.

Taking the error message literally, the error appears to be in custom code that is run by a action "OnShowRunJS".

  1. Do you have any actions inside the video object that are to be run at a certain time?

  2. Do you have any actions that are supposed to run at the end of the video?

  3. Is there an "On Show" action on the next page after the one that launched this video or on the pop up page that contains this video?

It is possible the client's browsers have an extension or s configuration setting that is causing the course to crash. Maybe have the client try the course with extensions turned off? Maybe turn on Developer tools and look at the Console tab and see if any red error messages appear.

Also, since the course crashes the same way, at the end of the video, on all three browsers, can the client try another computer on a different network to troubleshoot?

Thank you John, I apologize for the confusion.

The two actions on Done videos are:

1- Modify Variable that modifies the variable (Return to Page) to True;

2- Exit Action to close the pop-up window and return to the main window.

When testing it, it just closes the pop-up window and returns to the main one.

Many thanks again,

Thank you for the detailed information. In the images, I am looking at the actions on the video. The OnDone action says OnDoneExitClose, not OnDoneModvar as explained in the text. This action could be closing the course, not closing the page or the video, but the course. The ModVar explained in the text is in an OnShowModvar action, not a OnDoneModVar action as explained in the text. When testing, does the course close for you when the video ends?

Hi John,

Thank you for your response. To answer your questions, here's the "chronological" order of my actions, with screenshots, please note, though, that I followed the recommendations in the link posted above, and it worked perfectly fine with me:

1- In the main page, there's TimeInterval Action (figure1) to run an action group called (ReturnToPageGrp)

2- The ReturnToActnGrp (figure 2) has 3 actions: a- Modify variable; b- hide all, c- show one text block

3- When user clicks Watch Video button, they're taken to the video page

4- In video page, there's an On Show Page Action that has Run JS (figure 3)

5- This Run JS displays the button tip for keyboard users (figure 4) - nothing to do with the video

6- The video has an On Done action (figure 5) to Modify Variable (Return to Page) to True

Hope that explains it, and thank you again for all the help.

Hello again. I have more questions to continue to try and reproduce this issue. I've created a support ticket with eLearning Brothers so we can work offline on this issue. Once we determine the cause of this error, we can circle back here and report the findings for the community benefit.