Variables

May 01, 2013

I have a need to create the following with variables:

I want the user to be able to click a button 5 times and each time a different picture will display.  Someone did suggest using a variable that adds but I'm having problems making that work.

I have to use variables (this is a work sample for a new job)

Any suggestions

Thanks

4 Replies
Rebecca Fleisch Cordeiro

Hi Karen,

See if this meets your needs. I've only done 3 pictures, but you should get the idea

Create a number variable. I called mine count. Default is set to 0.

Insert a button and create a trigger for the button that

ACTION: Adjust variable

VARIABLE: count

OPERATOR: Add

VALUE: Value 1

WHEN: User clicks

OBJECT: the button you inserted

Insert the pictures. In my case, I made the initial state of all 3 hidden.

Then I created triggers to change the state of the pictures when the user clicked the button. For example:

ACTION: Change state of

ON OBJECT: Picture 1 Balloon flower

TO STATE: Normal

WHEN: User clicks

OBJECT: Button 1

ON CONDITION: count=1

and, if you check out the triggers, the BE Susans display if the count=2; the vinca displays if the count 03

This discussion is closed. You can start a new discussion or contact Articulate Support.