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

Captivate 6 - Strange Pause Behavior

Community Beginner ,
Jul 03, 2012 Jul 03, 2012

Copy link to clipboard

Copied

Hi All,

I am having a problem with the pause slide action in Captivate.  At the end of each slide, I want the playbar to pause and not automatically forward to the next slide.

Here's what I did to set it up:

  1. Under slide properties > action > on exit, set execute advanced action
  2. The advanced action is assign cpCmndPause with literal 1


In Captivate versions 3 - 5, that would pause at the final frame of a slide before loading the next slide.  In Version 6, it will forward to the next slide, then pause on the first frame.

I did find a workaround using javascript:

  • On slide exit, execute javascript in current window: PauseSlide();
  • In the published .htm file, I added the following lines of code after line 11

<script language="javascript" type="text/javascript">

function PauseSlide(){

     var currFrame = document.getElementById('Captivate').cpEIGetValue('rdinfoCurrentFrame');

     document.getElementById('Captivate').cpEISetValue('rdcmndGotoFrame', currFrame - 2);

}

</script>

Since the advanced action doesn't seem to occur until the first frame of the next slide, this script 'rewinds' the course to the last frame of the previous slide. It's a total hack.

Have you witnessed this too?

I am using the demo version of C6, and have found this behavior in the 64-bit version on win 7 and 32-bit version on win xp

TOPICS
Advanced

Views

14.2K

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 ,
Jul 03, 2012 Jul 03, 2012

Copy link to clipboard

Copied

Just checked it and you are correct. But why do you need such a complicated solution? I am called an "advanced actions freak", but to pause a slide at the end of its timeline, I would insert a click box somewhere and be sure its timeline extend to the end of the slide. Since a click box does pause the slide at the end of its timeline, slide will pause then. If you do not want the user to click by accident on the click box, make it pretty small and put it in a place where such a click is very improbable.

You have seen that the rd variables have been replaced by cp equivalents. In the JS you still use the old names, they are still available in the JS API (Jim Leichliter told me) but wouldn't it be safe to use the new names because they will certainly disappear some time? In case you want to stay with that solution (I'm a KISS fan as well).

Lilybiri

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 Beginner ,
Jul 03, 2012 Jul 03, 2012

Copy link to clipboard

Copied

Hi Lilybiri,

Thanks for your response!  The reason that I want to use the onexit action is that I can control the behavior globally, and it's faster than inserting a button on every slide and dragging it to the end of the timeline.  Also - to me it doesn't make sense to add an extra button to the slide when there is a built in method to do this automatically - onExit.  Learners who are using a screen reader may also be confused by the extra button.  My 2 cents, but thank you for providing an alternative fix - that would certainly work.

I submitted this as a bug since it worked differently in the previous 3 versions.

Thanks for pointing out that the variables are different when using javascript, forgot to mention that.  I originally tried using the 'new' variables in my javascript function but it didn't seem to work. So:

cpInfoCurrentFrame --> rdinfoCurrentFrame

cpCmndGotoFrame --> rdcmndGotoFrame

..kinda wierd I know.  I'm pretty usre that this is a bug, so once it's fixed I'll remove my hack.  Thanks again.

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
Enthusiast ,
Jul 03, 2012 Jul 03, 2012

Copy link to clipboard

Copied

Nah it's probably permanent. the Dev team made the decision a long time ago

to stick with some of the original RoboDemo (rd) variables for backward

compatibility...

Steve

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 ,
Jul 03, 2012 Jul 03, 2012

Copy link to clipboard

Copied

A click box is not a button, and if you insert one properly timed on one slide, it is a breeze to copy it and paste it to all slides. You had to attach the advanced action also to each On Exit event. I wouldn't call your observation a bug, it is just a change: the On Exit event is always very dangerous to use, I mostly recommend never to use it because in case you have another interactive object with navigation attached to it, this even will never occur.

I didn't check the JS variables, just learned recently from Jim that the old ones are still there in the JS API. But logically, since the new ones are there as well, they should be available to use IMO.


Lilybiri

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 Beginner ,
Jul 03, 2012 Jul 03, 2012

Copy link to clipboard

Copied

Dually-noted that a click-box is not a button.

The onExit action seems to behave the same as I would expect the onEnter action to function to work - on the next slide.  It's behaving differently from the previous 3 versions of Captivate I've used. Might be a bug.  I submitted a bug report, so hopefully one of Adobe's experts will take a look.

I would advise you to test the 'new' Captivate variables in a javascript function.  I just tested it again with the same results.  Here is the code I used with the 'new'  variables:

<script language="javascript" type="text/javascript">

function PauseSlide(){

     var currFrame = document.getElementById('Captivate').cpEIGetValue('cpInfoCurrentFrame');

     document.getElementById('Captivate').cpEISetValue('cpCmndGotoFrame', currFrame - 2);

}

</script>

The currentframe variable was 'undefined' at runtime.  I could not skip to another frame by using the cpCmdGotoFrame variable. Again, I had to use the following code with the 'old' variables to get it to work:

<script language="javascript" type="text/javascript">

function PauseSlide(){

     var currFrame = document.getElementById('Captivate').cpEIGetValue('rdinfoCurrentFrame');

     document.getElementById('Captivate').cpEISetValue('rdcmndGotoFrame', currFrame - 2);

}

</script>

Maybe there is a different method than cpEIGetValue/cpEISetValue to access the new variables? That would explain things..

thanks

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 ,
Jul 03, 2012 Jul 03, 2012

Copy link to clipboard

Copied

Maybe this article about changes in CP6 by Jim Leichliter could shed some light:

http://captivatedev.com/2012/07/01/adobe-captivate-6-the-javascript-api/

Lilybiri

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
Participant ,
Jul 03, 2012 Jul 03, 2012

Copy link to clipboard

Copied

Hi,

We can set following advance action to get this behavior:

Assumptions: Slide is 30frames/sec and display time of each slide is 3sec

Expression : cpCmndpause = 1+0

Expression : cpCmndGotoFrame= 89+0

This is applicable for the first slide , for the next slide we need to add "90*(slidenumber-1)" and replace 0 from the second equation. Example I want to set it for second slide then I will update the expression as               

Expression : cpCmndGotoFrame= 89+90

Hope this might give easy solution to the problem.

Regards,

Avinash

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 ,
Jul 03, 2012 Jul 03, 2012

Copy link to clipboard

Copied

Avinash:

Forgive me, but I don't think your "easy" solution would be very practical for e-learning developers that need to make a living out of developing courses for clients.

Unless I'm misunderstanding your solution, you seem to be suggesting something that would need to be updated slide by slide in the Advanced Actions code each time the e-learning developer made any changes to the duration of even one slide in the entire movie.

Is that correct?

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 ,
Jul 03, 2012 Jul 03, 2012

Copy link to clipboard

Copied

I totally agree with Rod here. Why make things so complicated when a simple click box can solve what you want?


Avinash, this is really not a nice solution, sorry for my remark. You will expect the developer to calculate that number for each slide? If we had a system variable that shows the duration or the number of frames in the current slide it could be changed so that the same action could be used for each slide, but we have not. But this seems more like an expression whe use often here to point to administratives: 'Why make it easy when you do it in a complicated way?'

Lilybiri

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
Participant ,
Jul 04, 2012 Jul 04, 2012

Copy link to clipboard

Copied

Hi,

Rod & Lilybiri thanks for your honest opinion , I totally agree that  solution which I provided was not efficient for advance use, hmm.. also clickbox is a easy work around no doubt in that, well I tried with different expression and it worked for all the combinations.

Now I changed the second expression as :

Expression : cpCmndpause = 1+0

Expression : cpCmndGotoFrame=  cpInfoCurrentFrame -1

and there is no need to update this expression , author may use this expression on slide exit for every slide.

PLease let me know your opinion on this .

Regards,

Avinash

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 ,
Jul 04, 2012 Jul 04, 2012

Copy link to clipboard

Copied

This makes more sense, but I have another question:

Why are you using Expression in the first clause? 

Why not just use Assign cpCmndpause = 1  ?

Am I missing something?

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
Participant ,
Jul 04, 2012 Jul 04, 2012

Copy link to clipboard

Copied

Hi Rod,

We can also use Assign cpCmndpause =1 that makes no difference.

Regards,

Avinash

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 ,
Jul 04, 2012 Jul 04, 2012

Copy link to clipboard

Copied

Want to repeat my warning that On Exit event is not sure at all to be executed, if the playhead doesn't reach the last frame which can be caused by another ineractive object that navigates directly to some slide.

Lilybiri

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
Guest
Jul 04, 2012 Jul 04, 2012

Copy link to clipboard

Copied

Hey there ,

First I am newbie to this forum .. I'd like to thank you guys 'cause you all make so much effort to resolve our issues.

I also faced similar issue, read all the post above could understand wich option should I adopt ? I am not a script person neither my students  so want to stay away from it, I liked the clickbox idea but not sure if I want to put an extra object on my slides. Finally tried expression options described above, it worked somehow but scared of Lilybiri's warning.  Lilybiri can you  describe  more in detail when OnExit event will not fire ( with an example if possible) because if some object is navigating me  to some slide I dont want on exit action to pause me . Can you make me understand this ?

Rest my students are liking captivate, and I am impressed by new Themes  and software simulation...they are cool !!

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 ,
Jul 04, 2012 Jul 04, 2012

Copy link to clipboard

Copied

Hello,

timeline.png

In this screenshot you see a button with the default settings: duratoin 3secs, pause at 1.5secs. The success action for that button is also the default one 'Go to Next Slide'.

When this slide is playing, the playhead will start at the first frame, move on and stop at frame 45, because of that pause (default frame rate = 30fpx, so 1.5secs = 45 frames). When the user clicks on the button, the action 'On Success' of that button is executed, the playhead moves immediately to the next slide, which starts at frame 91. The frames between 45 and 91 will never be visited, and the On Exit action of the slide will not be executed because the last frame (90) of that slide will never be reached.

Lilybiri

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 Beginner ,
Jul 05, 2012 Jul 05, 2012

Copy link to clipboard

Copied

Hi All

Lilibiri - thanks for posting Jim's artice about javascript variables.  It states that you need to access the variables through the m_varhandle object.  I tried that with the 'new' variables:

var currFrame = document.getElementById('Captivate').cpEIGetValue('m_VarHandle.cpInfoCurrentFrame');

document.getElementById('Captivate').cpEISetValue('m_VarHandle.cpCmndGotoFrame', currFrame - 2);

Still doesn't seem to work.  Interestingly, Jim's article lists all of the properties withtin the m_varhandle object, and the 'new' cp variables are nowhere to be found.  The 'rd' commands are still in there...

Avanish - You don't need to use the rdCmndPause command before rdCmdGotoFrame.  the gotoframe command automatically pauses the playhead.  If you want the course to continue playing after you jump to another frame, use cpCmndGotoFrameAndResume

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 Beginner ,
Jul 05, 2012 Jul 05, 2012

Copy link to clipboard

Copied

BTW - just got an email from Adobe:

"Thanks for reporting the issue. This is a bug in CP6."

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 ,
Jul 05, 2012 Jul 05, 2012

Copy link to clipboard

Copied

In the list that Jim published with the properties of  m_varhandle, I did see the new as well as the old variables? Checked several of them.


I hesitated to point out to Avanish that cpCmndGotoFrame does stop the playhead... had already been bit too critical in another thread.

Lilybiri

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 Beginner ,
Jul 05, 2012 Jul 05, 2012

Copy link to clipboard

Copied

Yes I do see that now, strange that I couldn't get it to work.  Now i'm just using the non-javascript method as suggested by avinash.

onExit > execute advanced action

expression cpCmndGotoFrame = cpInfoCurrentFrame -1

This is satisfactory until the onexit bug is fixed. Thanks all

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
Explorer ,
Jul 10, 2013 Jul 10, 2013

Copy link to clipboard

Copied

Thanks swmangold

On Exit > Execute Advanced Actions
Expression
cpCmdGoToFrame = cpInfoCurrentFrame - 1

worked for me (Cap6)

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 ,
Jul 10, 2013 Jul 10, 2013

Copy link to clipboard

Copied

Be careful with that work flow not to get into a loop...Because if you have an action Continue triggered by an ineractive object, you'll get again to the last frame, this advanced action will again be executed and slide will be frozen...

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
Explorer ,
Jul 11, 2013 Jul 11, 2013

Copy link to clipboard

Copied

LATEST

Hi Lily

It's ok, I don't have any 'Continue' actions. Thanks for the warning anyway.

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
Guest
Jul 10, 2012 Jul 10, 2012

Copy link to clipboard

Copied

Hi there,

Lilybiri- Thanks for explaining me the on exit concept but I see no point in executing on exit action on navigating to  some other slide. If on exit says pause ,and I have a button which says jump to some slide I dont want on exit action interrupting me in between, and if I want  increment/decrement assign etc , I will go with On enter slide action rather than on exit , may be my understanding is different but I think this is very rare scenario.

Also I think solution provided by Avinash is correct , cpCmndpause =1 is required, I tried only with cpCmndGotoFrame = cpInfoCurrentFrame -1 but on HTML5 o/p i saw  play pause button is changing their states very quickly, but when I put cpcmndpause =1 it work'd perfectly fine,  @swmangold and Lilybiri did you check HTML5 o/p without pause thing, please let me know your observations.

@Avinash - finally your solution worked for me , but can you suggest me something better, When I am pause and if I want to continue I have to press Next button to continue ,  is it possible that if I press play button and I  go to next slide ?

Danny

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 ,
Jul 11, 2012 Jul 11, 2012

Copy link to clipboard

Copied

OK, I didn't explain well again, give up. Just warned that the On exit action (which I didn't say that it would be a navigation action) will not be executed if you have another interactive object that triggers navigation. I have been answering so many questions where an On Exit action seems not to be functional just because of that. Terminology is confusing: On Exit doesn't mean when leaving the slide, it means when reaching the last frame of the slide.

Will check the HTML-difference where the normal behavior of an standard action, not releasing the playhead, should be disturbed as you say. I didn't see such a behavior until now, but that doesn't mean you are not correct.

Lilybiri

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