• Global community
    • Language:
      • Deutsch
      • English
      • Español
      • Français
      • Português
  • 日本語コミュニティ
    Dedicated community for Japanese speakers
  • 한국 커뮤니티
    Dedicated community for Korean speakers
Exit
0

Advanced Action not toggling Closed Captions

New Here ,
Aug 28, 2020 Aug 28, 2020

Copy link to clipboard

Copied

I've run into a problem trying to use Advanced Actions to turn on/off closed captions for a custom button I created. I'm using Advanced Actions because I am changing the state of the button (to a custom state).  I did exactly the same thing with a "mute/sound on" button and it works perfectly. 

 

Here's the script to be executed when someone clicks on the button:

 

If

cpCmndCC is equal to 0

 

Actions

Assign cpCmndCC equal to 1

Change state of ClosedCaption to CC_ON

 

Else

Assign cpCmndCC equal to 0

Change state of ClosedCaption to Normal

 

Half of the script works fine. The button starts in "Normal" state and when you click it, it changes to the "CC_ON" state and the captions are turned on.

 

But the other part doesn't work.  Once the captions are on and the button is the "CC_ON" state, you can't turn them off, etc.  So apparently the action isn't resetting the cpCmndCC value to 0.

Like I said, I did this exact same thing with mute/unmute, and it works perfectly.  I can't figure out why it's not working unless there's a bug.

 

Views

539

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
community guidelines
Community Expert ,
Aug 28, 2020 Aug 28, 2020

Copy link to clipboard

Copied

I use the same shared action for all toggle buttons. Do not use Assign, but the Toggle command in both parts of the conditional action. Here is the post about that shared action:

http://blog.lilybiri.com/1-action-equals-5-toggle-buttons

Sorry, example movie is still SWF.  

Just tested the action in 11.5.499, works perfectly.

Votes

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
community guidelines
New Here ,
Aug 28, 2020 Aug 28, 2020

Copy link to clipboard

Copied

I just tried that with captions and it's not working.  I went back and did it with Mute/Sound On, and for sure, Toggle is working there, just as Assign did.

 

It's looking to me like there could be a bug with turning captions back off.

Votes

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
community guidelines
Community Expert ,
Aug 28, 2020 Aug 28, 2020

Copy link to clipboard

Copied

Which version are you using?  Do you not believe me when I told that I hve tried it just now for HTML5 output, in the most recent version which is 11.5.499.

Votes

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
community guidelines
New Here ,
Aug 28, 2020 Aug 28, 2020

Copy link to clipboard

Copied

That's the version I'm using. I've tried it numerous times and it works
with mute/unmute but not closed captions. It doesn't make sense to me.
I've cleared my browser cache every time, too.

Votes

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
community guidelines
Community Expert ,
Aug 28, 2020 Aug 28, 2020

Copy link to clipboard

Copied

Which Browsers did you use for testing? Did you test after uploading to a webserver?  Is something wrong with the setup of the CC? I can only testify that the shared action works perfectly in several browsers on my system. That means no bug is the cause, but the origin of your problems seem to be elsewhere...

Votes

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
community guidelines
New Here ,
Aug 28, 2020 Aug 28, 2020

Copy link to clipboard

Copied

Well, apparently it only "works" while captions are actually showing.  Not sure how to explain that, but I created captions and generated speech and as long as the captions are displaying, I can turn them back off.  Once the caption stops displaying, even though the caption window area is still there, I can't turn it off with the button.  It retains the "on" state. Oh well, Guess that'll have to do.  (Mute doesn't work that way..it'll go on and off whether there's audio playing or not.)

Votes

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
community guidelines
People's Champ ,
Aug 28, 2020 Aug 28, 2020

Copy link to clipboard

Copied

What you are describing started when they gave you the ability to resize captions, 2017 I believe.

 

I think you may be able to use a user variable instead, something like ccShowing, that what I use if someone shows the TOC sho the captions don't show over the top of the TOC.

 

I also use JS for most of that in most courses so I autoaticlly show the CC button disabled at the end of the slide.

Votes

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
community guidelines
Community Expert ,
Aug 29, 2020 Aug 29, 2020

Copy link to clipboard

Copied

It works exactly the same way as the CC button in the Skin (playbar). If you try to turn off CC while there is no longer text with that button, it will not turn it off. I cannot remember if that was also the case in previous version. 

Votes

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
community guidelines
Community Expert ,
Aug 29, 2020 Aug 29, 2020

Copy link to clipboard

Copied

Just to throw another idea into the mix here.  I have seen situations where some of the System Variables did not work well if used in the Conditional Statement of a Conditional Action. 

 

Off hand I cannot remember which specific System Variables created the issue, but I remember having a conditional action that did not work as expected and the reason turned out to be that I had to replace the System Variable in the Condition with a Custom User Variable instead.  Basically that User Variable had to mimic the value of the System Variable so that the toggle action worked. The same Condition Action allowed me to use Assign or Toggle actions to change the values of the System Variable (which was only a Boolean variable anyway) but I just wasn't able to use the System Variable inside the Condition statement itself.

 

Maybe that's something you can check.

Votes

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
community guidelines
New Here ,
Jun 23, 2021 Jun 23, 2021

Copy link to clipboard

Copied

Hi David, I know this was posted ages ago, but hoping to get an answer.

I am having exactly the same problem with a custom button with an advanced action, the same as the mute button, doesnt matter if i toggle or assign, when going into the second slide, the CC button does not show the correct state, although the captions do show as set in the previous.

Did you manage to work it out? If so how? 

Votes

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
community guidelines
New Here ,
Jun 23, 2021 Jun 23, 2021

Copy link to clipboard

Copied

Unfortunately I did not find a solution. The captions themselves toggle
correctly, but the button state does not. It makes no sense at all because
the button for audio (on/off) toggles just fine.

Votes

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
community guidelines
Community Expert ,
Jun 23, 2021 Jun 23, 2021

Copy link to clipboard

Copied

Did you ever try the action which I proposed? It works perfectly for me, but it is a shared action.

Votes

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
community guidelines
New Here ,
Jun 23, 2021 Jun 23, 2021

Copy link to clipboard

Copied

I am using a shared action. It didn’t work, no matter how I set it up. The caption button *does* toggle, but does not so so correctly consistently. I have not established a pattern. I have mimicked exactly what I did with the audio button, but it simply does not work consistently with captions. I just resigned myself to the fact that it’s not reliable and hopefully users who want captions won’t be confused.

Votes

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
community guidelines
New Here ,
Jun 24, 2021 Jun 24, 2021

Copy link to clipboard

Copied

LATEST

Hi David
Don't worry, I had exactly the same problem where everything should have been correct but still didnt work consistently, rather frustrating.
A little bit of perserverence (stubborn determination) and I think I worked it out going by RodWard's suggestion. 

If you create a variable (Closed_caption_state in my case) and replace cpcmndCC in the button's (conditional) advanced action (which I then made a shared action), you can use this variable to assign cpcmndCC with 0 or 1 (off or on) in another tab.
I created two tabs on the action and also had an advanced action (now also a shared action) in the slide entrance action to check the state. I have multiple tabs for slide entrance to numerous navigation controls.

Closed Caption Advanced Action on button.png

Closed Caption Advanced Action on slide entrance.png

Hope this helps you. 

Votes

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
community guidelines
Resources
Help resources