For both the processes, place the text box with the variable name between the two ‘%’ symbols (as shown below) at the place where you want to see the slide number. This adds the value to the variable in the text box that is between the two ‘%’ symbols in the preview.
Let’s see both the strategies.
1. Using trigger
It’s an easy way to add slide numbers in Storyline using triggers. It involves just 2 steps.
- Create a new variable and set the name as ‘pageNumber’ and set its type to ‘Number’ and retain its initial value as zero (default).
- The second and last step is to add a trigger, which changes the pageNumber to a number which you want to add to your slide. For our illustration, let’s set it to 1.
We can now preview the slide to find the page number added.
The script will be included to the trigger by clicking on the Script button, which is highlighted on the above screenshot/image. All we have to do is just paste the below code in to the script area and click the OK button.
var player = GetPlayer();
Here GetPlayer is the method used to get the properties of our storyline player and SetVar is to set the page number to 1. Replace 1 in the code above with the desired number in each slide to add that as current slide number.
That’s it! We have now finished the two ways of adding slide numbers in Storyline.
Do you find this useful? Please do share your comments and information, if any.