HTML5 output issue: Adjust variable when state of object is...

May 06, 2014

This works in Flash output but not in HTML5 output.  I have a trigger on the main slide that says to adjust the value of a variable to true when 4 buttons are in the 'done' state.  The variable changes in the Flash version but not in the HTML5 output version.  Why doesn't this work, and if it is a bug, then what is a good workaround?

7 Replies
Christine Hendrickson

Hi Chere,

Without seeing how your course is set up, knowing how you're accessing the course, and testing - it's difficult to confirm this is a bug. 

Are you able to share the .story file for your project here, so we might take a look?

Also, if you could let us know how you're publishing (Web, LMS) and what web browser(s) and versions you're using, that would be helpful.

Thanks!

Chere Chete

Thanks for looking at this Christine.  I published to Web, ticked off all options (HTML5, offline) and viewed it in Chrome on a PC.  To test the file, click on each Check button, then click Submit.  Do this 4 times until all the Check buttons are in the Done state (background is now grey).  Once all 4 have changed to this state, the trigger says to adjust the 'allRated' variable to True.

Christine Hendrickson

Hi Chere,

It looks like the issue lies with the custom state of "Done" for some reason, triggering this doesn't change the variable, so the layer never shows. 

However, if you change the state to a built-in state, say "Disabled" for example, it works just fine in HTML5. 

This would go ahead and gray out your buttons, similar to your custom "Done" state as well.

I made these changes to the file you shared and published:

Flash

HTML5

I've also attached the modified file.

Please let me know if this works on your end.

Thanks!

Hassan Mujtaba

Hi Chere,

Your trigger should work in html5 output, but for some reasons it is not. In this situation, Christine's solution of using disabled state makes sense. 

However, it is still possible to change the value of allRated variable based on DONE state of all four buttons. I was able to do that in two different ways. First solution is attached.

Thanks

Chere Chete

Christine,

For the benefit of those reading this post for their own HTML5 issues, I wanted to point out that your solution to use a built-in button state works if you choose "Disabled" state.  But it did not work when I used the "Selected" state.  Clarification - the variable changes but then the trigger to show a layer when the variable changes did not work.  All triggers work when I use the Disabled state.

This discussion is closed. You can start a new discussion or contact Articulate Support.