Blog Post

Articles
4 MIN READ

Create Conditional Interactivity in Storyline 360 with “If” Statements

CommunityTeam's avatar
10 years ago

One of the most common ways to add interactivity to e-learning is to include triggers. Triggers are events that cause specific actions to occur, such as jumping to another slide. But have you ever wanted your course to jump to a slide only if all the buttons on a slide have been selected? This is called conditional interactivity—interactivity that only occurs when certain conditions are met.

You can create these kinds of interactions in Storyline 360 by adding conditions to triggers—and it’s super easy! Let’s look at how it works. 

Opening the Trigger Wizard

All new projects have prebuilt player triggers—which control the Previous and Next buttons—located in the trigger panel. Of course, you can also create additional triggers.

To begin adding conditional interactivity, simply double-click the trigger you want to customize, and the Trigger Wizard editing window will appear.

To add a condition to the trigger, click + if to display the conditions drop-down list—which is categorized by Variables, Objects, and Window

These three categories give you tons of options for triggering conditional interactivity in your courses. Let’s explore each category in more detail.

Using Variables for Conditional Interactivity

Variables are used to track information and control elements across slides, scenes, or an entire project. Storyline 360 includes a variety of built-in variables you can choose from, or you can create your own custom variable

Let’s say you want to allow learners to proceed to the next slide when they click a Submit button only if they’ve entered something—like their name—in a text entry field on the slide.

First, create a trigger. 

Then, in the conditions drop-down field, select the Variables category, and choose the variable you want to use. In this example, it’s TextEntry.

Then, choose (is not equal to) as the operator for the condition.

Finally, select the value for the variable, in this case (blank).

And that’s it! Your conditional trigger is all set to go. In this specific example, learners won’t be able to navigate to the following slide until they’ve entered their name in the text entry box.

Adding Conditional Interactivity with Objects

The second category is Objects, which allows you to create conditional interactivity based on the state of any of the objects on your slide. 

Before we dive into how that works, let’s quickly go over what states do, in case you’re not familiar with them. States change the appearance of an object based on a learner’s actions, such as altering the color of a button when a learner hovers over or clicks on it. This gives learners visual feedback based on their actions, so they know that what they’re doing is working. 

Now that you know how states work, let’s talk about how they can help you create conditional interactivity. Let’s say you want to ensure that learners interact with a particular button on a slide before moving forward. You can add a condition to the Next button trigger so that it only jumps to the next slide if the state of a certain button on the slide is “Visited”—meaning the learner clicked on it.

To do this, open up the prebuilt trigger associated with Next Button / Swipe Next in the triggers panel. 

Then, click on the Objects dropdown and select the button you want learners to click on before they move forward. 

Then, select (is equal to) as the operator for the button.

Once you select an operator, you’ll be prompted to select a state from the drop-down menu. In this example, it’s Visited.

And that’s all there is to it!  

Basing Conditional Interactivity on the Course Window

The final category is Window, which lets you set up a condition based on where the slide is being displayed: in the player frame or in a lightbox

Let’s say you want to create a trigger that only activates if the slide is inside a lightbox. With conditional interactivity, that’s easy to do! In the “If” box, choose the Window category and select This Slide Is Lightboxed

And you’re all set! 

More Resources

With the help of the trigger wizard, you can add conditional interactivity to your projects quickly and easily—allowing you to customize your Storyline 360 courses even further. We can’t wait to see how you put this feature to good use!

Have any interactivity tips and tricks of your own? Share them in a comment below!

Want to try something you learned here, but don’t have Articulate 360? Start a free 30-day trial, and come back to E-Learning Heroes regularly for more helpful advice on everything related to e-learning.

Published 10 years ago
Version 1.0
  • NatashaGurm's avatar
    NatashaGurm
    Community Member
    Brilliant, Nicole, thanks for this. I'm still relatively new to Storyline and whilst I've got my head around the basics, it's these extra tips and tricks that are such a help.
  • jeff's avatar
    jeff
    Community Member
    Lol, I had totally forgotten about the window option. I was fighting a lightbox interaction a few weeks ago and just couldn't figure it out. Doh! Doh! Doh!
  • MirandaLee's avatar
    MirandaLee
    Community Member
    Does anyone have an example of the "window" trigger in action? I'm trying to wrap my head around that one. Thanks!!
  • AH2's avatar
    AH2
    Community Member
    Hi

    Does anyone know if I can use IF statements to create gamified 'trophy cases'? For example, when a certain condition is met (e.g. completion of part of the course), a badge will appear on a linked slide.

    Thanks.
  • MishaAgunos's avatar
    MishaAgunos
    Community Member
    can you list values in the condition functions?
    e.g. "textvariable != Not equal to (ignore case) word1; word2; word3"
    or would I need a separate condition for each word?