Hi, I have created one button to stop the playing flash media. I have written custom javascript like below mentioned but for some reason it's not working. Also I can't use the default stop method provided because I will be using this javascript in other tool. Could you please help me on this?
var annot= this.media.getAnnot({ nPage: 1, cAnnotTitle: "test.swf" });
var rendition = this.media.getRendition("Rendition-Test");
var settings = app.media.getRenditionSettings({ rendition: rendition });
settings.windowType=app.media.windowType.docked;
settings.autoPlay = false;
settings.repeat = 0;
var args = { rendition: rendition, annot: annot, settings: settings};
var player = app.media.openPlayer( args )
player.stop();
Open the properties dialog for the Media, if "Edit Flash" is on the title bar for the window, you have a Rich Media annotation and the code above won't work. If "Multimedia Properties", then you have a screen annotation and the code you have above won't work because it has a bug in it.
Thom Parker
The source for PDF Scripting Info
[url=http://www.pdfScripting.com]pdfscripting.com[/url]
The Acrobat JavaScript Reference, Use it Early and Often
[url=http://www.adobe.com/devnet/acrobat/javascript.php]http://www.adobe.com/devnet/acrobat/javascript.php[/url]
Thom Parker
The source for PDF Scripting Info
www.pdfscripting.com
Very Important - How to Debug Your Script