Forum Discussion
Numeric variables: Default of "zero" isn't treated as a number?
In SL3 I have a numeric entry box, assigned to the variable "NumericEntry". In "Manage Project Variables", the default value for NumericEntry is listed as zero. I want to prevent users from advancing without entering a value, so my "Continue" button has a trigger to display an error layer if NumericEntry = zero. However, Storyline isn't recognizing NumericEntry as a number until the user enters a value. As proof of this, when I put a text box with "%NumericEntry%" on the page and preview, the text box is blank. It should show a zero.
I can't cheat and use text entry, because I need to do calculations with this number later in the project. I also can't put a trigger on the slide to set the variable to zero when the timeline starts, because if I do that, SL3 auto-fills the numeric entry field with a zero instead of the text I chose, which is "(enter #)"; The instructor doesn't want the autofilled zero, because when students click in the box the cursor appears after the zero, leading to a high likelihood that users will begin their entry with zero (e.g. "0100" instead of "100"). This also breaks calculations later.
It seems that if SL3 is telling me the default value is zero, then it should be the number zero, and be usable in calculations.
Is this a glitch, or am I missing something?
24 Replies
- AnaSentkowski-3Community Member
I am having the same issue. I have a slide with a few Numeric Entry Fields. Their according Variables default value should be zero (according to the Variables Panel) but Storyline doesn't recognize this value. If I set a trigger to eg. jump to next slide when all of these variables are zero, it doesn't work because Storyline apparently sees them as empty/"blank".
It makes no difference if I change the name of the variables or the Entry Fields or not. The Numeric Entry Fields variables seem to be "blank" by default and if I trigger them to be set to 0 when Timeline starts I see this default value, which is not desired.
And I don't want the user to be able to insert Text, so switching to the Text Entry Field isn't an option either.
Are there any news on this glitch? It's really frustrating trying to figure out a walk-around for this issue.
Hi Ana!
We haven't heard of this bug regressing! Are you on the newest update for Storyline 360? We are currently on Update 34 (Build 3.34.20804.0).
If so, it would be best to begin working in a case so that we can get a better idea of what you're experiencing. Please use this link to submit a case.
- PeterBabiCommunity Member
Hi to all!
Do we have SL3 update of NumericEntry default 0 too?Or any other ideas / suggestions?
- VinceScomaCommunity Member
Hi Peter,
Happy to help here!
While I don't have an update for Storyline 3, a recommended workflow is to assign the value of 0 to a Numeric Entry Variable using a Trigger:
If you continue to run into a snag here, I reccommend opening up a Support Case so we can provide a more tailored solution!
- RobertLaw-f070fCommunity Member
Was this issue resolved? I am trying to create a slide which adds up a short column of numbers. The result is NaN. Two numeric input fields display 0 (although one of these only shows when the field is highlighted). No other numeric fields display 0. The formula result from adding the fields is NaN, if any fields are included other than the two which display 0. Articulate 360 v3.40.22208.0
Hi Robert,
I'm sorry you ran into this! We have documented a few scenarios where can NaN appear. Can you help me with a few more details?
- Do you have any unused question banks in your file? If so, does deleting them remove the NaN?
- Do you have a trigger that adjusts the variable without learners needing to type in a number? If so, what happens if you create a trigger to adjust the variable and set it to 0 when the timeline starts?
We'll work on our next steps from there!
- RobertLaw-f070fCommunity Member
Hi Katie
I want to add a short column of numbers (accountancy training).
I can get every cell to start with zero, by having a starting value of 1 and then deducting 1 when the timeline starts. This results in all input boxes showing 0, instead of blank. It also results in a leading zero to a number input. All in all, it does not look professional. It is not good.
Thanks
Robert
Robert Law BSc FCA
AAT Tutor
01392 435349
robert@accountancylearning.ac.uk
www.accountancylearning.ac.uk
Southernhay Lodge, Barnfield Crescent, Exeter, EX1 1QT
Company Registration Number: 3454405
COMPANY NOTICE
This e-mail, including any attached files, may contain confidential and privileged information for the sole use of the intended recipient(s). If you are not the intended recipient (or authorised to receive information for the recipient), please contact the sender by reply e-mail and delete all copies of this message.
If this e-mail contains attachments, you should ensure they are checked for viruses before opening them.
Please consider the environment before printing this email.
Unsubscribe
Hi Robert!
We appreciate the extra details! To continue investigating the snag, we'll want to take a look at the .story file. Are you able to share your project with us?
If so, here's a secure upload link. You'll receive a notification when we've received the file and we'll keep you updated on our findings!
- WendyWilliams-8Community Member
I see several old comments about the default zero but I don't see how it helps me :(.
We have discovered that when a fill-in field is set as a number variable, it defaults to a ‘0’ in the blank. You actually have to DELETE the 0 in order to put in the correct number. In other words, just putting your cursor in the field doesn’t make it go away. I have tried but cannot set the Default to ‘blank’ and if you don’t delete the zero before you type the number it stays at the beginning and then the answer is incorrect. (i.e. 0 becomes 0563 instead of just 563.) Is there anything we can do to resolve this? Many will have trouble as they won't think to delete the zero.
I am attaching a sample. (the correct answer is: 2)
Thank you,
Wendy
Print Designer/Tech Writer
- MariaCSStaff
Hi, Wendy.
Will you need to use that answer (W2s) in any calculation? If not, my suggestion is to use a text variable instead of a number:
I hope this helps!
- WendyWilliams-8Community Member
no we don't need it for a calculation BUT we want to restrict them from entering text, the answer must be numbers. We have done the text box with 'numbers only' in some places, but we were hoping for a real solution rather than a work-around.
Also, will changing to a text box solve the issue where '0' is the answer? Right now if you try to enter '0' as the answer it says 'you must answer the question before clicking submit' (or something like that). We need to be able to use the '0' as the actual answer.
Thanks!
Wendy
Print Designer/Tech Writer
Related Content
- 10 months ago
- 10 months ago
- 10 months ago
- 10 months ago
- 10 months ago