Forum Discussion

StefanieKirs743's avatar
StefanieKirs743
Community Member
3 days ago
Solved

PIN Entry Not Working

Hello Community!

I've got this slide on my project where the user has to enter a PIN. In each box, a bullet is supposed to appear (non-negotiable, has to be bullets) using code because I do not have a bullet point font.

This slide has been working for weeks until all of a sudden, I went to test it today and it only allows me to input a value for the variable "Box1".

Can someone please take a look at slide 4.3 and see if you can figure out what happened? There is a button on the first slide that will allow you to jump right to the slide in question so that you do not have to go through half the project to get to that slide.

 

Thanks in advance!

  • The variable PinIndex_3 is missing. Also PinIndex is missing for slide 5.5 and PinIndex_2 for the question in the quiz. To fix create the 3 variables named as above (number, default value 1). 

7 Replies

  • That is a lot of code for a slide where bullets need to be entered into a textbox. I can't say I really understand all of it as taking it apart would require some time, but the browser console keeps returning this when I click any keypad button:

    What is PinIndex_3?

    Edit: Does this accomplish the same thing?: pinEntry | Review 360

  • DShaw's avatar
    DShaw
    Community Member

    The variable PinIndex_3 is missing. Also PinIndex is missing for slide 5.5 and PinIndex_2 for the question in the quiz. To fix create the 3 variables named as above (number, default value 1). 

  • CarlFink1's avatar
    CarlFink1
    Community Member

    Why do you need a "bullet point font"? Just use character 25CF (●) from the Unicode version of a standard Latin font.

    • DShaw's avatar
      DShaw
      Community Member

      Fair point on the font, there's no such thing as a "bullet point font", it's just a character, and virtually any standard Latin font includes one. The code isn't there for the glyph, though, it's there for the input logic. SL has no native masked PIN entry, so the JavaScript is what decides which of the six boxes fills next, bumps the index along and handles backspace. Doing that with built-in triggers would be something like sixty odd conditional triggers across the keypad! The script already does exactly what you're suggesting, it types a plain bullet character into a text variable. One caveat on 25CF specifically, agreed it's the better-looking dot for a PIN, and it's a one-character swap in the trigger. But SL subsets embedded fonts to the characters used at design time, and 25CF doesn't appear anywhere in this project's authored text, a glyph injected purely at runtime can fall outside the subset and fall back (or render as tofu).

      • CarlFink1's avatar
        CarlFink1
        Community Member

        I was not arguing with the excellent solution, just wondering about the idea of needing a specific font for bullets.