Highlighted

Toggle between two states based on variable

New Here ,
Nov 16, 2018

Copy link to clipboard

Copied

Hello,

I'm trying to get a blinking effect on an object by having it toggle between two states based on two variables:

Blink (The variable that toggles between "0" & "1", which also changes the state of the object based on the value.)

runBlink (The variable that runs the WHILE loop, causing the previous variable to toggle between "0" & "1".)

When I preview the slide, the runBlink variable successfully toggles the Blink variable between "0" & "1". However, the Blink variable isn't changing the state of the object as it is supposed to be.

Am I doing something wrong, or is there a better way to accomplish this?

Views

197

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more

Toggle between two states based on variable

New Here ,
Nov 16, 2018

Copy link to clipboard

Copied

Hello,

I'm trying to get a blinking effect on an object by having it toggle between two states based on two variables:

Blink (The variable that toggles between "0" & "1", which also changes the state of the object based on the value.)

runBlink (The variable that runs the WHILE loop, causing the previous variable to toggle between "0" & "1".)

When I preview the slide, the runBlink variable successfully toggles the Blink variable between "0" & "1". However, the Blink variable isn't changing the state of the object as it is supposed to be.

Am I doing something wrong, or is there a better way to accomplish this?

Views

198

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
Nov 16, 2018 0
Engaged ,
Nov 16, 2018

Copy link to clipboard

Copied

It would be helpful if you show a screenshot of your action - please click the Preview icon above the action name to make it easier to see the whole action.

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
Reply
Loading...
Nov 16, 2018 0
Most Valuable Participant ,
Nov 16, 2018

Copy link to clipboard

Copied

Can you please post a Preview of the used advanced action? I want to see how you set up the While loop.

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
Reply
Loading...
Nov 16, 2018 0
Enthusiast ,
Nov 16, 2018

Copy link to clipboard

Copied

Just a thought about the technique you are trying to achieve - if you are required to make the content ADA compliant - flashing or blinking objects are not really supported by accessibility standards.

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
Reply
Loading...
Nov 16, 2018 0
Participant ,
Nov 16, 2018

Copy link to clipboard

Copied

Maybe I'm oversimplifying this, but the loop here does what you describe.

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
Reply
Loading...
Nov 16, 2018 0
Most Valuable Participant ,
Nov 20, 2018

Copy link to clipboard

Copied

Could even be more simple, you don't need to identify the state, just use 'Go to Next State'. I don't know how quick the blinking should happen, that is why I asked for a screenshot of the AA.

BlinkAct.png

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
Reply
Loading...
Nov 20, 2018 0
Participant ,
Nov 20, 2018

Copy link to clipboard

Copied

Yes, that would work too. In my simple example I had a Normal state in addition to the Green and Red states; that's why I elected to call the two custom states explicitly.

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
Reply
Loading...
Nov 20, 2018 0
New Here ,
Nov 20, 2018

Copy link to clipboard

Copied

Here is a snapshot of the advanced action:

Screenshot.png

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
Reply
Loading...
Nov 20, 2018 0