Need a sanity check for an advanced action
Hi everybody,
I've been working on what I thought was a simple advanced action to essentially hide a slide and disallow access until an interaction is successfully completed. For some reason I can't get it to work and I can't find the error in my logic. I'm hoping fresh eyes/brains will catch what I can't!
Slide A is part 1 of a 2-part interaction. Upon visiting slide A, a variable (VAR) is assigned '0'. At the end of the advanced action to verify the correct answer, VAR is assigned '1' when the answer is correct.
Slide B is part 2 of the interaction. I want this slide to only be accessible after part 1 is successfully completed. After the slide has loaded there's an action to assign a second variable, var_slide_status with 'visited'.
Slide C comes after B and is just a regular slide, not part of the interaction. On slide entry, VAR is assigned '2'.
Slide B has a validation advanced action that manages different navigation scenarios, it goes something like this (using multiple decision blocks):
- if var=0, jump to Slide C (skips Slide B since Slide A wasn't answered correctly)
- if var=1, continue and assign var_slide_status with 'visited' (Slide A answered correctly, Slide B continues and assigns a variable saying it has been visited)
- if var=2 AND var_slide_status != 'visited', jump to Slide A (allows for backward navigation while skipping Slide B)
- if var=2 AND var_slide_status='visited', continue (allows backward navigation to Slide B so user doesn't have to re-do Part 1)
- if var=0 AND var_slide_status='visited', continue (allows re-navigation forward since VAR will revert back to 0 when Slide A is re-visited)
Right now, the navigation isn't working as expected. The back and forward skipping Slide B works fine if Slide A is not answered correctly or isn't attempted. Slide B also shows up fine when Slide A is answered correctly. The problem lies when Slide B is accessed and I move forward to Slide C. Every time I click back from Slide C, instead of going back to revisit Slide B as I hoped, Slide C reloads itself. If I click twice really fast, it will jump to Slide A, but never Slide B even though it has already previously been visited. Then when it takes me back to Slide A, when I go forward
I hope this makes sense because I had a time figuring out to begin with. It makes sense to me but clearly I'm not doing something right. Can anyone take a look and figure out what I'm doing wrong?
