Trigger actionscript from end of captivate movie
Hi Guys,
I'm going insane trying to work out how to trigger an
actionscript event from the last slide of my Captivate movie.
Basically I'm doing a product walk through which I am exporting as
a swf an then dynamically loading into my flash file.
I need to be able to detect when the externally loaded
Captivate swf has completed playback so that I can then continue on
with the rest of my flash movie.
I have tried adding a swf in Captivate with actionscript to
trigger the event at the end of the slide but it doesn't work?
I have also tried exporting the whole thing as an fla and
then re exporting it from Flash MX 2004 and the animation seems to
get ruined and out of synch.
Any ideas on how I can detect and trigger and AS event when
the loaded Captivate swf has completed would be much appreciated.
Thanks heaps for reading.
Chris
hi Chris
i created a similar workaround. i ran into a number of issues
when trying to call an actionscript function at the end of a
Captivate swf. i determined that captivate is VERY picky about
imported swfs. for instance, i had a single imported swf that
contained an animated background and one line of actionscript, and
it never worked. however, when i split it into two separate swfs
(one just for graphics, one just for actionscript), it worked! go
figure.
i also noticed you have to be careful where you place it on
the captivate timeline, depending on what you're trying to do. if
you're calling an end-of-movie function, be sure the swf is only on
the last few frames of the last slide. sometimes when i placed the
actionscript swf on the first frame of my last slide it wouldn't
work, but after moving it down a bit, it worked fine.
lastly, i had to use "_root" to get mine working. i know many
people consider it bad form, but if it works, it works. i did the
following:
1. created a function in my Flash interface named "endDemo()"
2. created an empty Flash file with one line of actionscript:
_root.endDemo();
3. imported the swf into my captivate movie and placed it on
the last few frames of the last slide.
4. set my captivate movie prefs to stop at the end of the
movie, and not to fade out.
worked for me... good luck!
- philip
Similar Messages
-
How to create a smooth transition from end of a movie clip to beginning of a movie clip?
I have a motion tween that is 180 frames in length. When the tween ends on the last frame and returns to the first frame to replay there is a slight jump in the tween. Is there anyway to stop the tween from jumping from last frame to the first?
The answer lies in the first posting you made for this topic. You shouldn't start a new discussion for the same topic.
-
Using Actionscript or Javascript to unload movie using Captivate 5.5
I have an application an agency built that houses my training videos (created with Captivate 5.5). Now users can click to start a video and then immediately close it and the application shows that they viewed/completed the entire movie. I need to find a way for Captivate to send a call (or something) to the application telling it that the movie has finished.
I do not know much Actionscript or Javascript but I am a fast learner. I read in past posts where this was accomplished in Captivate 2.0 and 3.0 by
1) coping the captivate movie into Flash and adding two lines of code (Actionscript)
import flash.external.Externalinterface;
External Interface.addCallback("unload", this, unloanSQF);
2) the following would be added to the HTML page
//Detect Flash container movie
function getFlashMovie(movieName) {
if (navigator.appName.indexOf("Microsoft") != -1) {
return window[movieName];
else {
return document[movieName];
//Function to be called by Captivate
function captivateUnload() {
//Calls "unload" method established in ExternalInterface Actionscript code
getFlashMovie("simpleSwfLoader").unload();
3) Add the Javascript call captivateUnload() to the Captivate button.
I am hoping that the procedure has gotten better with 5.5; plus I do not want to use a button. I want the unload event to occur automatically when the movie ends. Plus, I can't see how to produce a fla version to be imported and edited in flash.
Any help or direction would greatly appreciated.
Thank you, JimIt sounds like you will need to change some functionality in the application that launces your Captivate SWF's. Currently they will be set to "completed" once they have been opened. The correct approach would be to have your application set them to "Incomplete" or "In Progress" and then have Captivate execute a JavaScript on the last slide calling a function in your application that sets the module as completed.
/Michael
www.cpguru.com - Adobe Captivate Widgets, Tutorials, Tips & Tricks and much more.. -
Prevent Captivate movies from autoplaying
Hi I wonder if you can help. I would like to prevent my Captivate movies from automatically starting when the page loads. For accessibility reasons it is always better to allow the user to control video so that users of screen readers do not get confused by an unexpected voiceover.
However I don't want to re export all the Captivate movies and was wondering if there is a quick fix I can do to the code like autoplay="false"?
Thanks for your help
StevenUnder Preferences > Project > Start and End > Untick the box for Autoplay.
-
Can we move back an instance from end to previous activity?
Hi,
Using Oracle BPM WL 10.3 MP2, Can we move back an instance from end to previous activity? If yes are there any ways to make this happen? I guess that instances which are aborted cannot be brought back from end activity? but not sure.
Any ideas / suggestions?
Thanks,
-SreeIf the instance was aborted due to an exception, you could have an exception handler which would allow you to handle the error, and then retry if desired...
However, once the instance is at End, its done...
-Kevin -
Controlling Captivate movies from a parent Flash movie
Hello, i am in the works of onverting my old AS2 code, for controlling Captivate movies lodaded into a Flash container, over to AS3 becasue of the transition to Captivate 5. There were some weird issues in AS2 and Captivate 3 which i fortunately vere able to solve when i first made this container. Now i am getting weird and unpredictable results when trying to set the appropriate variables in the Captivate move. The main culprit is: rdcmndRewindAndStop, it does indeed rewind the movie, but... it starts playing again... Could anyone be so kind to give me the reason why or better even provide me with a solution to this unneeded change, its quite annoying, and no rdcmndPause does not help, not before rdcmndRewindAndStop or after, the movie is happily trottling along...
sincerely
Frustrated developer with a bloody short deadlineHello and thanks for replying, yes it worked! But... we have to manually edit 40+ files to make this stupid thing to work... Do you know if there is any way i can put those scripts in a flash object, or better even modify the movie from the parent container? This is making our production process way longer than is affordable tbh, a single project consists usually of over 100 captivate movies, and we simply can't manually edit each and every one of them.
I wish i could get my hands on a Captivate developer ;p -
Move minus sign(-) from end to start of field
Hi,
How to Move minus sign(-) from end to start of field. i e if var = 120-, i want to display it as -120.
if any one has the code , send me.
Thanks in advance
Krishna.Check the code, i hope it serves your purpose...
data:
var(10),
length type i.
var = '300-'.
write var.
length = strlen( var ).
length = length - 1.
replace first occurrence of '-' in var+length(1) with ''.
concatenate '-' var into var.
write:/ var.
Reward points if useful, get back in case of query...
Cheers!!! -
Is it possible to access an object inside a Captivate movie from Javascript?
For example, my JavaScript performs some processing, based on which a particular button inside the movie needs to be hidden. Can I access a particular button from JavaScript to be able to do this? If not, then is it possible to be notified inside the Captivate movie, when a variable has been set by JavaScript? I notice that the JavaScript interface in Captivate 8 provides an event (CPAPI_VARIABLEVALUECHANGED) which fires when the value of a variable inside the Captivate movie changes. If there was a similar event which would fire inside the Captivate movie, when a variable changes then I could have set a variable using JavaScript and hidden a particular button using an advanced action, when the event for that variable changing fires inside the Captivate movie.
Articulate Storyline has an event which gets triggered when the value of a variable changes (either because of JavaScript executing or otherwise). If something similar was possible in Captivate, it would open up many possibilities.
I am evaluating Captivate 8.
Thanks in advance for any help.hi
Yes. its possible but its not recom
you can set in production system to allow changes to obj rsa1->transport connection->click 'object changeability', and look for object type , and set to changeable.
pls refer these below posts
transport a query backwards, from production to development
Re: Transporting Process Chains from Production DOWN to QA and Dev
assign points if useful.....
Shreya -
Deleting Inserted Captivate Movies from RoboHelp 7?
How do you delete Captivate movies that you insert into
RoboHelp 7? It seems like it should be easy, but I don't see how.
Thanks,
Tom
blog:
http://idratherbewriting.com
podcast:
http://techwritervoices.comThanks Rick. My problem was that I was trying to delete the
swf file directly, rather than deleting the topic the Captivate
movie was inserted on. After deleting the topic (or companion page)
like you said, the swf is removed automatically.
On another note, I was reading an instructional article by
John Daigle on Captivate 2 and RoboHelp.
http://www.adobe.com/devnet/captivate/articles/cp_rh_integration_06.html
In the article, he describes a workaround for getting the player
controls and border to appear when you insert a Captivate movie
into RoboHelp (a Captivate movie that was created outside of
RoboHelp). However, I've found that when I import the Captivate swf
file with the word _skin in it (there are a couple of swf files
Captivate outputs), the borders and player controls appear
automatically without the workaround. Is this a bug that Captivate
3 and RoboHelp 7 fixed from the previous version? -
I am loading a swf that I created in captivate into another
flash file. I would like to be able to detect when tha captivate
swf is at the end. Is there a way in flash to detect when a
captivate swf is at the end?Hi Jencarter,
another possbility could be to embed a small swf-animation
into the captivate-movie that calls a function in the root, in this
case the flash-file which loads the captivate-movie.
We had the same problem, in the flash-file a function
"chapterend" should be called as soon the captivate-swf is at the
end.
So I've build a small swf which just calles the actionscript:
_root.chapterend();
This swf can be imported into the last slide of the
captivate-movie (or on any other position, if you need it).
Best regards -
Closing swfs in captivate movie
I am frantically trying to figure out how not to get a
javascript erro rwhen my animation ends inside my captivate movie.
how to I close the swf adn still elt the user navigate to the next
captivate screen?
Please help!
thanks,
francieHi francie
I have no clue as to how what terrence wood is suggesting
will help here. From what I surmise based off what you posted, you
have inserted an animation or possibly even another Captivate movie
on a slide in an existing movie? And somehow you want to know how
to close the .SWF that is sitting on the slide? If I'm correct in
what I understand you are trying to do, my guess is that it isn't
possible. Why? Well, if you were able to close the .SWF on the
slide, you would probably also close the whole movie. My guess is
that this is why you are seeing JavaScript errors.
I'm thinking that you should probably configure the end
option to simply stop. For the movies that are on the slides, that
is. This also assumes you are placing other Captivate movies on the
slides. If you are instead placing other animation, I haven't a
clue what to advise, other than to possibly adjust timing.
Hopefully this helped in some way... Rick -
Active Content when RH topic contains Captivate movies
I use Robohelp to display my captivate movies (published as
FLASH).....since the Active Content issue in the latest IE update,
my users now have to click on the movie before it becomes
interactive.....I've managed to fix the topics in RH that don't
have a movie inserted on them....but if there's a movie, my fix
doesn't work unless I modify EACH htm file (each topic's code).
This works great except that EVERY time I re-compile the RH
project, the fix is overwritten.....
My fix involves a javascript include file......
Thanks.
PamHi again Pam
Hmmm, well I'll see if I can help any. I'm not sure what you
mean with "fixing topics in RH that don't have a movie inserted".
What are you fixing? Why is a fix needed if a movie isn't there?
But on to the actual issue at hand. You are saying that
something is being overwritten? Perhaps it will help to outline the
process as I envision it.
1. You have a topic containing a Captivate movie that is
interactive, meaning the user must click or type somewhere to
interact with it.
2. Before the fix is applied, the user must click or press
the spacebar in order to "activate" the control. This is equivalent
to patting Internet Explorer on the head and saying "It's okay.
Really. The world will, in fact, NOT end if you just show me the
content and allow me to click it."
3. You apply the fix, which means to use an external
JavaScript file (.JS file) to perform a "write in" of the code
needed to present the movie.
4. You generate WebHelp (assuming WebHelp here, as I do not
believe this issue manifests from inside a compiled .CHM file) and
something gets overwritten?
And here is the quandry. I'm assuming you are intent on
asking either how to prevent the overwriting from occurring, or
possibly WHY it's being overwritten. Perhaps both?
I think the first step is to determine if the WebHelp
generation process is actually overwriting files. I'd compare the
HTML code of a topic that works fine prior to genning WebHelp, with
the same topic code after the generation process has occurred. What
has changed with respect to the code you inserted? Is the code just
gone? Or is it possibly an issue whereby the .JS file simply hasn't
survived the WebHelp generation process? I'm guessing the latter.
You may simply need to add the .JS file to baggage.
Cheers... Rick -
Import from Powerpoint to Captivate 1.0
I'm trying to simply automate a series of Power Point slides
in Captivate. My company has a standard slide format that has
footers with clear text on a colured background. Although the slide
content comes in clearly the footers are blurred, the characters
seemingly merging.
I ideally wanted 800x600 for best web look, but have tried
1024 x768 but the image still appears blurred. I think I have tried
every setting of properties. Any ideas?Hi steve10150 and welcome to our community
Perhaps an old post from one of our former Adobe Community
Experts will help here. Blurry text from PowerPoint imports is a
very common complaint.
===============> Insert Paste Below
redvic 08/01/2005 03:52:22 PM
When importing PPT slides to a movie, can I stretch the slide
to fit the Captivate movie frame? I see nothing in help.
In an existing movie, I import PPT slides but there is a
white edge on the left & right sides of the frame.
Tommy Simmons 08/01/2005 05:56:58 PM
redvic,
It sounds like you have a slight mismatch between the aspect
ratios of your Captivate movie and the PowerPoint presentation. It
strikes me that you could either try 1) using "File > Page
Setup" in PPT to change the aspect ratio of your PPT and then do a
manual capture/import operation into Captivate of the selected
slides, or else 2) if a straight manual capture would not produce a
scalability problem for the slide in Captivate, you could use the
PPT splitter bars to resize the thumbnail image in Normal view to
whatever you need and then manually capture the slide, taking care
to crop the slide top and bottom to get the aspect ratio the way
you need. Hopefully someone else can suggest a more elegant
solution - good luck!
redvic 08/02/2005 09:13:57 AM
Hi,
Thanks, your first suggestion worked! I did not know I could
do a custom-sized PPT slide. I did File > Page Setup and chose
"Custom" for Slides sized for field. Then, I specified the height
and width of the slides based on the size of my existing Captivate
project. For this, I had to convert pixels of the Captivate project
to inches in PPT. I divided the pixels dimensions by 72 and got the
approximate inches. For example, 798x546 in Captivate converted to
11.1" x 7.6" in PPT.
redvic 08/02/2005 03:57:09 PM
Hi,
A caveat to this solution: When I switched to a Custom sized
PPT slide size, PowerPoint automatically adjusted the font sizes,
too. For example, I increased the width of the PPT slide a little
bit and my 24 pt Heading font became 26 pt. Our corporate standard
is 24 pt. So, I had to go into the slides and adjust the font sizes
back to the corporate standards.
=========================> End Pasted Text
Hopefully this helps... Rick -
Rewind Captivate movie in PowerPoint
I've managed to get a Captivate movie into PowerPoint
following instructions found at
http://www.flashgeek.com/tutorials/
However, although I've followed the instructions, I can't get
the movie to start at the beginning each time the slide with the
movie displays.
Can anyone help with precise instructions on how to rewind
the movie?If you deselect "Borders" under Project/Skin the navigation
bars are included in the resulting swf. Which you can embed in
powerpoint.
There is some little trickery with VBA you can use to start
the movie automtically:
(sorry it is partly in german because of my program skin)
In Powerpoint open the Toolbar „Steuerelement
Toolbox“ or open it with (View / Symbolleisten / …).
There click on “weitere Steuerelemente“ klicken
(Symbol with a hammer).
In the alphabetical dropdown list select „Shockwave
Flash“ .The mouse changes to a cross with which you can open
a rectangle on the slide. There the video will appear later. Now it
is filled with a big "X".
Right click on the rectangle and select "Properties". There
behind "Movie" enter the name of the video (if it is at the same
location) or the path.
If you choose TRUE after "embed movie" the resulting
powerpoint presentation contains the flash movie, if you choose
"false" it just links to it. So you can either assure that the
video is part of the presentation or you can update the
presentation by naming a new video identically to the old one and
the link in your presentation now shows the new video (do you
understand what I mean?)
If you start your presentation the video starts (even if it
is on the last slide). You can restart it automatically by doing
the following:
Double-click on the rectangle whre your video will be shown.
The VBA editor opens in a new window. There click on Insert/modul
in the toolbar.
The modul is a editor-window where you now place your code.
Copy&Paste the following (example from me for three movies just
edit it depending on your needs):
Sub OnSlideShowPageChange()
Dim film1 As ShockwaveFlash
Dim film2 As ShockwaveFlash
Dim film3 As ShockwaveFlash
Set film1 =
ActivePresentation.Slides(2).Shapes("ShockwaveFlash1").OLEFormat.Object
Set film2 =
ActivePresentation.Slides(3).Shapes("ShockwaveFlash2").OLEFormat.Object
Set film3 =
ActivePresentation.Slides(4).Shapes("ShockwaveFlash3").OLEFormat.Object
film1.Playing = False
film2.Playing = False
film3.Playing = False
film1.Rewind
film2.Rewind
film3.Rewind
film1.Play
film2.Play
film3.Play
End Sub
This is doing the following:
Each time you enter a slide with a flash-video the video is
rewind and played from the beginning. In this example there are
three videos in the presentation. Do not change the order of the
commands or it will not work!
The numbers in ( ) are the number of the slide on which the
movie is appearing (here: the 2nd, the 3rd and the 4th). The name
of the movie which you can find in the properties behind "name" or
"title" is also entered. If you make a mistake here the code cannot
affect your movies. Keep in mind that the numbering of the slides
in the presentation is to be used, not the numbering shown in the
vba editor, which you can see on the left (where you also see your
module)
In this example the movie „Shockwaveflash1“ is on
the second slide.
Then click on "Save" in the vba editor and close the window.
Now test your presentation... It should work just fine! -
Viewing a Captivate movie in streaming
Hi -
Would appreciate receiving help in how to publish my Captivate movie so that viewers can view it while it's streaming and not downloaded before viewing begins.
Thanks in advance,
DGR2Hello again
I may be mistaken here, but I think what you are looking for is a preload. So to set this (assuming you are using Captivate 5) click Edit > Preferences > Project > Start and End. There you should find the ability to configure a Preloader.
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
Maybe you are looking for
-
Going back to previously opened file
When going to "File" and "Open" in any application program in operating systems prior to Leopard, it would not only take you back to the folder you had just been to, but also highlight the last file you had opened. In Leopard, it only takes you back
-
I recently upgraded from FF4.0 to 5.0.1 and now whenever I start Firefox I receive an error message. When I click on OK in the message Firefox continues to load and appears to operate normally.
-
I am getting dump while downloading
i am getting dump while downloading file to presentaion server . please suggest me . code is like below. PARAMETERS : p_dwn TYPE dxfile-filename. AT SELECTION-SCREEN ON VALUE-REQUEST FOR p_dwn. CALL FUNCTION 'F4_FILENAME' EXPORTING PROGR
-
Unicode in Labels, Buttons,...
Hi, I want to use unicode in my applet. I know that I can use unicode characters by drawString() method of Graphics class but I want to use unicode characters in Label, Button,... components. I tried to use bellow command to show \ufe78 th character
-
Hi, I have really a serious problem about storage unit type controlling in my wm project. I desinged the warehouse system according to some backround jobs like RLAUTA10. All my storage types managed with stoge units but we have just one storage unit