Storyline 3: Numeric Entry Field (avoid duplication of numbers)

Jun 23, 2018

Hello,

Hope someone can help with my Storyline 3 project.

I have slides with 5 numeric entry fields. 

Question 1: Is there a way that I can only enter numbers 1 to 5 in each field.

Question 2: Is it possible that if the user type in number "1" in any numeric entry field, then he cannot use that number anymore. (The user is only allowed to use each number once)

See attached storyline file and excel file. I want to convert the excel file into a Storyline project so I can publish it as SCORM and upload to my LMS. 

 

4 Replies
Marinel Enaguas

Hello Walt,

Attaching my story file. There are variables included in my project that is why Sequence Drag and Drop I think is not applicable. 

Do you think there is a better way to do this? Sorry just new to Storyline, and doing some experimentation to make it work. 

Thank you. 

Steve Gannon

Hi Marinel,

See the attached Storyline 3 file.

Examine the triggers I added to the first situation slide (I didn't do the others). Some of the triggers use JavaScript to validate the value the user entered. Layers are used to warn the user if the value is not between 1 and 5 or warn if the value has already been used.

As I currently have it coded, this will take quite a few triggers per situation slide. If you're comfortable with JavaScript, you could instead use arrays to reduce the number of triggers required. (I didn't use arrays in case you're not familiar with them and also so that the JavaScript I did use would be easier to follow.)

In addition to the two requirements you listed in your first post above, I also added a trigger to round each value on the off chance the user enters, say, 4.7 rather than just 4.

I added conditions to your ADD triggers so that the value would only be added to the respective "attitude" type if it was valid (that is, between 1 and 5 and not already used).

You may also want to add a trigger to reset the value just entered back to zero if it is invalid (not between 1 and 5 or already used).

Hope that gets you started!

 

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