• Global community
    • Language:
      • Deutsch
      • English
      • Español
      • Français
      • Português
  • 日本語コミュニティ
    Dedicated community for Japanese speakers
  • 한국 커뮤니티
    Dedicated community for Korean speakers

Executive Actions Freezing

Explorer ,
May 11, 2021 May 11, 2021

Copy link to clipboard

Copied

I have an executive action that I am trying to execute.  It works perfectly until the correct combinations of variables is correct, then this does not work:

 

So I have 6 conditions where they must be all met.   

lmaley_0-1620753037349.png

 

Once they are all met, they should do:

lmaley_1-1620753112360.png

 

But when they are all met, it just does nothing.   It will not change the state of my box or show the next button.  If I click on a wrong box to highlight it, then it works again, but every time I have the correct combination clicked it just freezing up.

 

What I am trying to do, they have to click the correct graphs to answer the question, once they get the right sequence of graphs clicked the next button shows up.  I have a square over each graph with no color or outline that has a clicked state and it turns green when clicked and does not show if not clicked or clicked a second time.  If I have the wrong graphs clicked, the second box of If statements works fine and the green shading shows/disappears as they should.

 

lmaley_2-1620753202029.png

 

My untitled 2 which is the second round of conditional tab - I only have two.  This section works perfectly.

 

lmaley_3-1620753397308.png

 

lmaley_4-1620753450937.png

 

 

 

I have captivate 11.5.5.676.

 

What am I doing wrong?

Views

1.5K

Likes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines

correct answers 1 Correct answer

Community Expert , May 11, 2021 May 11, 2021

One of the first things to learn about advanced actions is that it ALWAYS will read and execute all commands, as I wrote before: from top to bottom and from left to right.  You need to rethink your advanced action setup and take that into account. It is really worthwhile to take some training or read some tutorials about advanced actions.  

It is perfectly possible to make it work, but there is no way to only go to the second decision if the first one is false.

For starters with advanced actions

...

Likes

Translate

Translate
Advisor ,
May 11, 2021 May 11, 2021

Copy link to clipboard

Copied

I noticed some of your conditions say if greater than 0 and some say equal to 0

Not sure how you click boxes are setting those variables.

Could that be part of the problem?

Likes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Explorer ,
May 11, 2021 May 11, 2021

Copy link to clipboard

Copied

I don't think so, because it is working great except when all of them are at the correct setting.  I have done this before, just not with so many.

Likes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Advisor ,
May 11, 2021 May 11, 2021

Copy link to clipboard

Copied

A strategy I like to use is to place smartshapes on screen to display all my variable values so I can verify that they are changing WHEN I want them to and TO THE VALUE that I want them to.

It is a good way to troubleshoot and can lead you in the right direction to solving the issue.

Just a small smartShape with text  $$myVar$$  placed inside.

Replace  myVar with  the name of your variable.

 

Question - The correct setting is where you expect the changes to happen, right?  If it works great except when the settings are correct - does that mean nothing happens when the settings are incorrect? That would seem logical and would simply mean the settings are broken somewhere.

How do you know that the variables match your setting criteria? That's what the above strategy will help figure out.

Likes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Expert ,
May 11, 2021 May 11, 2021

Copy link to clipboard

Copied

It is a pain to try to understand your advanced actions. Please use the Preview window, where we can see multiple and complete decisions in one view. You open that Preview window using the first button (arrow) in the top right control panel. Especially since I have not even any idea how many decisions you have used. See this screenshot:

PreviewButton.PNG

There are unnecessary commands in the shown actions. Bu default any advanced action will keep the slide paused if the button triggering that action has a pausing point. Please show the Timeline, so that it is possible to see the triggering buttons. Adding a Pause command makes no sense whatsoever. In one action you add Continue, which makes sense if you want to override the pause by the pausing point.

If you want help, these details are needed:

  • Screenshot of the Timeline so that the pausing points of the hotspots can be checked.
  • Which event is linked to which action: I suppose the hotspots will trigger an action, but the first one you show is probably a second decision and belongs to the same action.
  • Screenshots of the Preview of the used advanced action. It is not necessary to post all actions if they are similar for each button.  You talk about '6 conditions', do you mean that you have 6 variables in the AND combination? How are those variables populated? Because I see only one variable which is assigned another value (IC) but that variable is not in the combined AND condition. Moreover that IC variable gets a value = =2 but you check the variables on a value == 0?

 

 

Likes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Explorer ,
May 11, 2021 May 11, 2021

Copy link to clipboard

Copied

lmaley_0-1620759590397.png

 

The next button is hidden initially.  I kept one pause point at the very end to keep it from going to the next slide prior to them answering correctly.

 

lmaley_3-1620759889396.png

 

What I am doing is creating 7 boxes that go over top the 7 graphs in this slide, the top left hand graph does not get one.

 

lmaley_1-1620759656101.png

 

When they click on a graph, the invisible box over top of it turns green to indicate that they have clicked on it.    Their variable gets assigned a 2.   If they click on it again, the green box turns back to invisible to indicate they have unselected it.   Their variable gets reassigned back to a 0.   So once the variables are all correct, the next arrow should come up.   (7 variables in all, but if they are clicking on the 7th one, I know what is going on with that one, so I only have to look at the other 6).  So I guess I can clean up the ones that I have 7 in there.

 

FC - I have tried removing the pause and played around with things and cannot get it to work.  I have done something similar with less variables and I had to have the pause in there prior to showing the next button for it to work.. no idea why???

 

lmaley_2-1620759829459.png

IC

 

lmaley_4-1620759974016.png

TS

lmaley_5-1620760012001.png

 

ICFC

lmaley_6-1620760046971.png

TSFC

lmaley_7-1620760075384.png

 

TSIC

lmaley_8-1620760108569.png

TS*FC*IC

lmaley_9-1620760138139.png

 

 

 

Likes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Advisor ,
May 11, 2021 May 11, 2021

Copy link to clipboard

Copied

Hmm...

 

Right now I am leaning towards an issue related to the order of operations.

An example might be checking for the conditions and then changing the variable rather than changing the variable and then checking if it meets the critera.

Something along that order. Like things are out of sync.

Likes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Expert ,
May 11, 2021 May 11, 2021

Copy link to clipboard

Copied

@Stagprime  There is a logical bug, I just described it in my answer. 

Likes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Expert ,
May 11, 2021 May 11, 2021

Copy link to clipboard

Copied

Still very hard to read. Please take out those unnecessary Pause commands. 

Since you never disable the first shape button, it is OK that you only have that one pausing the slide, but I would have kept the pausing point  for all interactive objects at the same moment. It is just before the end of the slide, which is fine.

However: if Untitled2 is always before Untitled1 there is something illogical.:

  1. If all the conditions are correct you will set the variable to 0 with the first decision Untitled2 (shows up as first in the Preview. The same condition will lead to showing the Next button. If the conditions are not fulfilled, nothing happens. So far OK, but....
  2. In the second decision (Untitled1) you check if the variable ==0. That will have been the case if the first decision was successful and .... you hide the Next button again. ???? You did override the result of the first decision.

I first thought it was a conflict with a label being used twice for different items (variable and button) but don't feel up to checking that. However I think it is the logical bug in your advanced actions which I just described which is the problem.

It would be a much better idea to rethink the advanced action and convert it to a shared action. You have forgotten that in an advanced action you cannot break out of the action as is possible with a normal programming lanugage. The sequence is imposed: top to bottom and left to right. Maybe you could reverse the two decisions and try again. Sorry, I couldn't do it because it is still a mystery to me how you populate the variables and why some conditions use a different operator (greater than instead of equal to).

 

Likes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Explorer ,
May 11, 2021 May 11, 2021

Copy link to clipboard

Copied

I thought if untitled 2 was true, it would not go to untitled 1?   I thought it only went there is Untitled 2 was false.  Is that not the case?  I understand why it is not working if it is not the case.  Is there a way to make it only go to Untitled 1 if untitled 2 is false?

Likes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Advisor ,
May 11, 2021 May 11, 2021

Copy link to clipboard

Copied

That is the nature of an IF / ELSE  statement

if something is true - do this

otherwise - do this

 

Untitled 1 has an IF / ELSE statement but Untitled 2 is a separate IF action on its own without any ELSE parameters

Likes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Explorer ,
May 11, 2021 May 11, 2021

Copy link to clipboard

Copied

So can you nested multiple IF statements in this?  Under one untitled?

Likes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Advisor ,
May 11, 2021 May 11, 2021

Copy link to clipboard

Copied

I do not believe so - I think you would need to be careful in setting up additional tabs in the proper way to avoid the conflicts.

 

Personally - I use JavaScript to manually create my advanced actions from scratch. There is a great deal more flexibility and, in my opinion, less confusion.

You can do nesting with coding directly.

 

Likes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Explorer ,
May 11, 2021 May 11, 2021

Copy link to clipboard

Copied

Ok  Thanks.  I did get it to work within about 5 minutes by switching the untitled 1 and 2 around and changing one line, in each executive action.  Now it works.   Yeah, I may try Javascript next time.   That would probably be easier.  Thanks for the advice!

Likes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Expert ,
May 11, 2021 May 11, 2021

Copy link to clipboard

Copied

LATEST

That was my suggestion to switch the decisions back to the original sequence. I have no idea why you reordered them.

Each method, advanced/shared action or JS programming language, has its advantages and disadvantages. Important is that you know the 'rules' and - for a programming language - that includes the syntax rules.  For this particular use case, it seems overkill for me although I have been programming since many decades. Much easier with a shared action, no need for syntax debugging. But Greg uses JS for almost everything, very logical that he will prefer JS.

Likes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Expert ,
May 11, 2021 May 11, 2021

Copy link to clipboard

Copied

One of the first things to learn about advanced actions is that it ALWAYS will read and execute all commands, as I wrote before: from top to bottom and from left to right.  You need to rethink your advanced action setup and take that into account. It is really worthwhile to take some training or read some tutorials about advanced actions.  

It is perfectly possible to make it work, but there is no way to only go to the second decision if the first one is false.

For starters with advanced actions I always give  tips:

  • Try to make decisions in sequence mutually exclusive, so that a following decision cannot override a previous decision. In the majority of cases this is possible.
  • Do not use ELSE part, except eventually in the last decision, if that ELSE part will not override any of the previous decisions.
  • Do not use commands in a conditional action if they have to be done always, but put them in an standard decision (no condition). The place of that standard action, at the start or at the end, will be decisive for the condirional decisions.

I would have given you a solution if I had a complete view of the actions and the difficult labels. But I recommend to take some training about advanced actions. Alternative would be to skip them and learn a full-blown programming language.

Reflect on the possible situations you'll have and put each of them in a decision. Do this with pen and paper or a digital alternative, but not in Captivate. Is it necessary to combine 'equal to' and 'greater than' operators? I don't see why that is needed. 

Likes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Explorer ,
May 11, 2021 May 11, 2021

Copy link to clipboard

Copied

No problem.  I know why it is not working.  I can get it working.  I just have to change how I did it.   thank you again!  You are always very helpful.

Likes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Expert ,
May 11, 2021 May 11, 2021

Copy link to clipboard

Copied

OK, fine. You probably will not forget this particular feature anymore. Everyone learns most from their bugs, have struggled with this multiple times when I started using Advanced actions. However I insist that a shared action could be a better idea, but it needs a different mind set.

Likes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines