Build a slider (the candling slider)
Build a slider that writes a number variable as the learner drags it, show the value with %Light%, and open a layer when it passes a threshold. Works by mouse, touch and keyboard, in preview and in your LMS. Dials work the same way.
Last updated 6 min read
My Storyline course has a slider. How do I build one here?
Step by step
Insert a slider
Click Slider on the insert toolbar (or Cmd/Ctrl+K → "Slider") and drag out a box on the slide.
Give it a variable
In its properties, click Create a new number variable for this slider, then rename the variable
Lightin Variables.Set the range
Lowest 0, Highest 100, Step 5, Starts at 20. Or drag the thumb on the canvas to set where it starts.
Show the value
Add a text box:
Light: %Light%.React at a threshold
On the slider, add a trigger: When variable changes (Light) → Show layer Fertile, with the condition Light ≥ 70.
Preview
Drag the thumb, or tab to it and press the arrow keys. At 70 the layer opens.
What you'll build
A candling slider: the learner moves a lamp's brightness from 0 to 100, the slide shows the number as it changes, and at 70 a layer opens to show what a fertile egg looks like. It's the Storyline slider pattern, and the next rung on the project ladder after drag and drop.
Insert the slider and its variable
- Click Slider on the insert toolbar and drag out a box about 360 × 48 on the slide. A Dial works the same way and turns instead.
- In the properties panel, click Create a new number variable for this slider. That makes a number variable and points the slider at it in one step (one Undo takes both back). Rename it
Lightunder Variables if you like. - Set Lowest 0, Highest 100, Step 5 and Starts at 20. You can also drag the thumb on the canvas: with the slider selected, the thumb sets where it starts and the rest of it moves the object.
The slider writes Light continuously while it moves and once more where it is let go, just as Storyline's does. Starts at is applied when the slide starts, unless Light already has a value from earlier in the course. A slide set to reset to initial state puts it back every time.
Tip: The track's fill and the thumb's ring follow your course's accent colour. Change the track, fill, thumb, thickness and size under Look, or untick Show the value.
Show the value
Add a Text box and type Light: %Light%. While the learner drags, the number updates in place. That works in any text: a label on the slider, a speech bubble, a result line.
Open a layer at a threshold
- Make a layer called Fertile with a picture of a well-lit egg, set to start hidden.
- Select the slider. In Triggers, click Add Trigger.
- When: When variable changes, variable
Light. - Then: Show layer → Fertile.
- Add a condition:
Light≥ 70. Add Otherwise → Hide layer Fertile, so moving back below 70 closes it.
A slider's triggers are just its variable's triggers. Anything that reacts to Light reacts to the slider, wherever it sits on the slide.
Try it
Click Preview. Drag the thumb, or tap it on a phone. Then press Tab until the slider has focus and use the keys:
- ← → or ↑ ↓: one step.
- Page Up / Page Down: a tenth of the range.
- Home / End: lowest and highest.
A screen reader announces it as a slider with its value. While it has focus, the arrow keys move the slider, not the slides. Export it: it plays the same in your LMS.
Part of the documentation: Build.
Found something here that does not match what the product does? That is a bug in the guide — see all guides or tell us from the Help Center.