How to find HTML name of Action Group and run

kbutler3407
kbutler3407 Community Member Posts: 4 ☆ Roadie ☆

I have two actions in an action group and I would like to call them from inside some custom JavaScript I'm running. First, how do identify the HTML name of the action group?

Second, how do I call it in JS to run the action group?

Thanks in advance for the help.

Best Answer

Answers

  • kbutler3407
    kbutler3407 Community Member Posts: 4 ☆ Roadie ☆

    Thank you once again Wheels. I'll give this a try next week and mark it as answering the question once I see it works. I never would have gotten there on my own.

    Slightly related follow up question. Do actions within an action group run synchronously or asynchronously? So if I have three actions in a group in this order - A1, A2, A3 and A1 is using a variable's value and A3 is resetting the same variable's value is that safe or a potential race condition?

    Thanks again for the help.

    Kevin

  • wheels
    wheels Community Member, Administrator, Moderator, Rockstar Manager Posts: 685 eLearning ROCKSTAR Admin Team

    Hey Kevin,

    Wow, great question!

    With the default settings they will run synchronously (in order).

    If you add a "delay" then the actions would run asynchronously.


    This can be useful but complicates things as you can imagine.

    Sometimes I use delays on navigation actions because if those are done synchronously they can cause unexpected results. Like if there is a Go To Next Page action with a set complete status action immediately after it. Most likely the completion would not be set, and it might not be obvious to the course author. We've talked about modifying navigation actions internally to run asynchronously but have not done that yet.