Skip to main content
IHeartCaptivate
Known Participant
August 19, 2009
Answered

Captivate 4 - Advanced Actions - Pause/Play buttons

  • August 19, 2009
  • 3 replies
  • 7698 views

Hi - So I have created a 2 buttons - a pause and play - so my users can pause/play my captivate video (audio and actual slide). I have created my 2 variables for the buttons and I have created my advanced action. I'm assigning my pause to 'rdcmndPause', hide pause, show play. And I'm assigning play to 'rdcmndResume', hide play, show pause. It's not working. The pause/play buttons appear and disappear like they should - but my project isn't pausing or playing. Any thoughts?

This topic has been closed for replies.
Correct answer Paul_D

I'm not very good with AS3 but try this, removed some of your code and added a bit ;-)  worked OK for me

PauseButton.visible = true;

PlayButton.visible = false;

PlayButton.addEventListener(MouseEvent.CLICK,hidePlay);

PauseButton.addEventListener(MouseEvent.CLICK,hidePause);

function hidePlay (event:MouseEvent):void {

PauseButton.visible = true;

PlayButton.visible = false;

MovieClip(this.parent.parent).rdcmndResume = 1;

}

function hidePause (event:MouseEvent):void {

PauseButton.visible = false;

PlayButton.visible = true;

MovieClip(this.parent.parent).rdcmndPause = 1;

}

3 replies

August 26, 2010

Has anyone difinitively figured out how  to make a pause/play button? I'm using Captivate 4. Obviously the rdcmdpause function does not work. I really need someone to go step by step. I have wasted so much time on this, I'm thinking that captivate may not be the way to go.

Captiv8r
Legend
August 26, 2010

Welcome to our community

I'm assuming that since you are replying to a thread that is more than a year old that you have read the thread entirely. Assuming that you have, you will know that the only way to achieve this (in ANY version of Captivate to date - Including the latest version) is to create either a Flash object you insert or an official Captivate Widget (versions 4 and 5 only) to accomplish this goal.

If you would like to see the functionality eventually appear in Captivate you (and others that want to see this) need to submit a Wish Form to alert the development team to the need. (Link to the Wish Form is in my sig.)

Cheers... Rick

Helpful and Handy Links

Begin learning Captivate 5 moments from now! $29.95

Captivate Wish Form/Bug Reporting Form

Adobe Certified Captivate Training

SorcererStone Blog

Captivate eBooks

Known Participant
August 25, 2009

I created in Flash (AS2) the attached Pause/Play button, using the rdcmndResume and rdcmndPause' parameters.  The buttons work great.  As an added bonus, the Flash buttons can fade in and out unlike Captivate buttons.

One caution - I intended the button to "Display for: the rest of the slide".  If you want the button to "Display for: the rest of the project", use "_parent._parent.rdcmndPause = 1;" instead of "_parent._parent._parent.rdcmndPause = 1;" and "_parent._parent.rdcmndResume = 1;" instead of "_parent._parent._parent.rdcmndResume = 1;"

IHeartCaptivate
Known Participant
September 2, 2009

Ok - so new problem. I have a project that already has some AS3 in it, so I need a Pause/Play button in AS3. I got it to switch in my Flash file but I can't get it to stop the captivate file. I know my variables are rdcmndPause, and rdcmndPlay and I know that somewhere I need to have parent/root. But I don't know where to put it or if I should really even be adding it. this is what I have for my code so far...pointers anyone?

PauseButton.visible = true;
PlayButton.visible = false;
var rdcmndPause = 0;
var rdcmndResume = 0;

PlayButton.addEventListener(MouseEvent.CLICK,hidePlay);
PauseButton.addEventListener(MouseEvent.CLICK,hidePause);

function hidePlay (event:MouseEvent):void {
PauseButton.visible = true;
PlayButton.visible = false;
rdcmndPause = 1;
rdcmndResume = 0;
}

function hidePause (event:MouseEvent):void {
PauseButton.visible = false;
PlayButton.visible = true;
rdcmndResume = 1;
rdcmndPause = 0;
}

Paul_D
Paul_DCorrect answer
Inspiring
September 2, 2009

I'm not very good with AS3 but try this, removed some of your code and added a bit ;-)  worked OK for me

PauseButton.visible = true;

PlayButton.visible = false;

PlayButton.addEventListener(MouseEvent.CLICK,hidePlay);

PauseButton.addEventListener(MouseEvent.CLICK,hidePause);

function hidePlay (event:MouseEvent):void {

PauseButton.visible = true;

PlayButton.visible = false;

MovieClip(this.parent.parent).rdcmndResume = 1;

}

function hidePause (event:MouseEvent):void {

PauseButton.visible = false;

PlayButton.visible = true;

MovieClip(this.parent.parent).rdcmndPause = 1;

}

Inspiring
August 20, 2009

I just tried to do this in CP4 and I can easily get the rdcmndResume to work, but the rdcmndPause wil not work no matter what I try.

According to the information about using the variables you should be able to set rdcmndPause to 1 and then the movie should pause.  I tried to make a Flash file that sets the rdcmndPause = 1 when it's imported into Captivate. That works just fine and the project is paused as it should be.

I think that this is a bug in Captivate 4 with the rdcmndPause variable when setting it through Advanced Actions.

/Michael


Click here to visit the www.captivate4.com blog

Captiv8r
Legend
August 20, 2009

Hi all

I thought the fact pause didn't work was a bug myself and a few months back submitted as same to Adobe. According to the Captivate dev team it is *NOT* a bug and it works just fine. I don't remember the specifics, but it had something to do with the fact that it was an action and actions always continue (or something like that).

I disagree and feel it should work as one would expect, so it looks as though I'm not alone.

Perhaps it will help if others report it as a bug too!

Cheers... Rick

Helpful and Handy Links

Captivate Wish Form/Bug Reporting Form

Adobe Certified Captivate Training

SorcerStone Blog

Captivate eBooks

Captiv8r
Legend
August 20, 2009

Hi again

I forgot to add that you *can* make this work if you want to delve into the misty and mysterious world of JavaScript. That's how I made mine work. I don't have the script handy at the moment. If I did I'd post here. I'm about to leave for a bit. If I remember, I'll look it up when I return and post.

Cheers... Rick

Helpful and Handy Links

Captivate Wish Form/Bug Reporting Form

Adobe Certified Captivate Training

SorcerStone Blog

Captivate eBooks