Assignment/NOT Assignment Trigger Operators

Jun 17, 2019

Hello, Articulate Community!

I'm posting this discussion as a request from one of our Articulate users, and to provide information about Assignment/NOT Assignment Operators in Storyline to others as well.

When you add an "Adjust Variable" trigger, you might notice the "Assignment" and "NOT Assignment" operators and ask what these are, what they do, and when can they be used.

ASSIGNMENT

The Assignment trigger operator 'assigns' a value to an existing variable on trigger. When you create an Adjust Variable(action) trigger, the Assignment operator will instruct the trigger about what value it is adjusting to.

For example - a Text variable. If I want a text variable to be set to "Peter" when I click on a button, the trigger window would be:

Action: Adjust variable
Variable: (name of the text variable created)
Operator: = Assignment
Value: Value, "Peter"
When: User clicks
Object: (Button/object name)

So when I click a button, it will 'assign' a value for the variable.

The Assignment operator can be used on text, number, and True/False variables.

NOT ASSIGNMENT

The NOT Assignment operator on the other hand, will 'not assign' a value. Setting the operator to NOT Assignment will adjust the value to its opposite.

Note that NOT Assignment can only be used on True/False variables.

For example - if a True/False variable's initial value once the slide loads is True, and I don't want it to be True when I click a button:

Action: Adjust variable
Variable: (name of True/False variable created)
Operator: = NOT Assignment
When: User clicks
Object: (Button/object name)

When the slide/timeline starts, the variable is set to True. But once I click on the button, it will not be True (will be False). If it's been set to False (from NOT Assignment), and I click the same button again, it will not be False (will be True). You would use the = NOT Assignment operator if you want to adjust the value to its opposite.


Here's a sample output (slide 1 for Assignment, slide 2 for NOT Assignment):

https://360.articulate.com/review/content/d829c31a-55d4-4d17-8359-c467e1033f9e/review

Slides 3 and 4 are some possible applications of Assignment and NOT Assignment.

Also, If you wish to play around and tinker with the project file, you can download it here:

http://share.articulate.team/82d49c9aa74c

8 Replies
Joseph Francis

That functionality has been replaced with Toggle.

In the Trigger Wizard, select Adjust Variable. Select your True/False (otherwise known as Boolean) variable. Now, notice the word Set is underlined? You can either explicitly set the T/F variable's value to True or False, OR you can have Storyline toggle that value each time the trigger is invoked, by changing Set to Toggle.

Craig Bunyea

Thanks for pointing that out. Unfortunately I wish Articulate Dev Team would have left it as is, since sometimes you need to initialize variables on a start screen only if a value doesn't already exist, not necessarily flip the value, for example when you are using a variable to keep track of the visited states of subsequent screens.  Maybe I should try using a string, and check for "blank" vs the T/F boolean?

IT Software

But where is the option "Assignment" located in the 2023 version of Storyline? None of my dialog windows match the example images in all the posts on the internet so I am unable to perform the procedures in my own equations. I have all the Trigger Wizard data fields except for the salient one... "Operator."

Judy Nollet
IT Software

But where is the option "Assignment" located in the 2023 version of Storyline? None of my dialog windows match the example images in all the posts on the internet so I am unable to perform the procedures in my own equations. I have all the Trigger Wizard data fields except for the salient one... "Operator."

If you read through the previous comments, you'll see that the "Assignment" functionality was replaced with "Toggle" more than 2 years ago.

FYI: In the Trigger Wizard, all items with a dashed underline are editable.