externalinterface

How can I call an Actionscript function when the .swf is referenced by jQuery?

I have an .swf that I am embedding into HTML using the jQuery SWF Object plugin (http://jquery.thewikies.com/swfobject). I have a number of functions within the .swf that I need to call from within javascript functions. I've made these actionscript functions accessible to javascript by calling flash.external.ExternalInterface.addCallback...

Getting current URL in Flash from JavaScript using ExternalInterface and IE

Hi, I'm trying to get the current URL that the Flash player is on. Not the URL of the .swf file, but the URL that the browser is pointing to. Thus far I've used: var st:String = ExternalInterface.call("window.location.href"); Unfortunately this doesn't work in IE. From my research, I can see that it won't work with IE either way. The...

Make a call to javascript function from actionscript

Hi All, I am trying to make a call to javascript function from actionscript. As of now, I am using 'ExternalInterface' and could achieve partial success. I could make a call to function(without any scope resolution) like "scanDNA()", which is visible to all. But am not able to make a call to function(scope specified) like "Eukarya.An...

How do I tell when a swf file is done playing in C#?

I am playing a swf file in a C# program. I am able start the video, stop it, rewind it, etc., but I want to know the exact time when video has finished playing so that I can move on and do some other stuff. Can the flash externalInterface interface be used so that the C# can get a notification of when the video is finished? I don't wa...

Flash & Javascript cooperation problem

I need to call function in flash using javascript. For this purpose I use ExternalInterface class(example described in the end of http://help.adobe.com/ru%5FRU/AS3LCR/Flash%5F10.0/flash/external/ExternalInterface.html). But it does not work for me. swf declared in html page as: <object classid="clsid:d27cdb6e-ae6d-11cf-96b8-4445535400...

Javascript Global Keyboard Handling, not hearing A-Z Keys?

I am trying to use Javascript to intercept keyboard events, so I can do CMD-W for "close-window" and whatnot, inside a Flash application, so the Browser doesn't get to use them. Well, I am able to listen for ALT, CTRL, and CMD onKeyDown/onKeyPress events, but I am not able to listen to anything else... Here is the code, in the index.ht...

Opening popups from AS3 using ExternalInterface in Safari

hi, I'm using this code to open a popup ExternalInterface.call("function () { window.open('" + url + "','" + title + "','" + options + "'); }"); for JavaScript people: calling ExternalInterface.call(string); from flash player lets the browser do eval(string)(); as this call is within a click handler, it even works perfectly with Fir...

AS3 actionscripting

Hi, I'm embedding a flash file from an external domain and there is some JSON data in the page I would like to use in the movie. Whats the best method to get these variables without passing them on as a flashvars (I don't have control of the page it's embedded in). My only idea is to enable script access to 'always' and then get the ful...

How to create a web widget for my website users to insert on their blog ?

Hello, For my wishlist site, I would like to propose widgets to my users in order to publish their wishlist on their blog or personal website. The idea is to propose a few lines of code to my users that they only need to copy/paste to insert the widget displaying their wishlist. What is the best way to create/develop a widget ? I ha...

ExternalInterface-passing dynamic arguments to Javascript function

I'm having a problem passing dynamic variables to a Javascript function using ExternalInterface. The variables don't seem to be resolved correctly //CODE START var customInfo :String='some custom info' ExternalInterface.call("funcName", 'arg1Name', ' "+customInfo+" ') //CODE END In Javascript, I get 'customInfo' literally, it isn't...

How do I use externalInterface to allow Flash to call javascript to update a value on the screen?

I have a Flash movie that is embeded in a PHP page. The PHP page displays a value to the user (the number of images they have uploaded). When the user uploads a new image I want the value on the PHP page to reflect the change without refreshing the page. This value is retrieved from database using MySQL. So heres what Ive done so far - ...

AS3 ExternalInterface call using jquery

I'm calling into a flash app embedded in a html page using the ExternalInterface. The following code works fine (I'm using a button to test): $(document).ready(function(){ $("#button").click(function(){ var app = document.getElementById('ApplicationID') console.debug(app) app.pageUnloading() }) }) So th...

Does the ExternalInterface, in Flex 3, have a data size limitation?

I am using the ExternalInterface on Flex 3. We are actually using flex to compress a large amount of DOM data, so this is specifically being used with LARGE data. To further investigate, if there is a limitation, is this universal? (IE. Silverlight) First, let me state that this is being done with an application that was made by inexp...

External Interface not available

Im testing a program in FlashDevelop, which uses Flash player 10. Need externalInterface to work, but on running this simple test program, it displays "ExternalInterface is not available". What might be the problem here? How do I get ExternalInterface working? http://blog.flexexamples.com/2008/03/10/checking-to-see-if-the-externalinter...

Flash AS2.0 and JavaScript/jQuery (ExternalInterface) Communication

Hi there, Im trying to use JS to send data to my Flash AS2.0 music player with ExternalInterface, except there are no good tutorials or guides on ExternalInterface that I can find. I want to be able to change the current song in the player by clicking a JavaScript link, and on page / window load without clicking, play a default song. ...

unresolved symbols / missing ] after element list

I'm removing the button interface from a Flash AS2 drawing tool. All the actions performed by the SWF buttons are now called from the HTML via JS and ExternalInterface. The drawing tool can add text creating a TextField, and draw or add an image creating an empty MovieClip When the JS code calls the method to create the TextField, Fire...

Get ExternalInterface definitions in Javascript

Is there a way to get a list of the exposed functions from a Flash object? For example, you could get a list of all methods in an object by executing: for (var i in object) { if (typeof object[i] == "function") { console.log(i); } } The only issue is that this won't expose any methods registered through the ExternalInterfaces...

Actionscript 3 ExternalInterface, Pass variable to javascript?

Hi, How would I go about passing a variable to a javascript function using ExternalInterface? ...

How do I use Flex's ExternalInterface with IFrames?

I have a simple html doc with a flex app and an iframe side-by-side (using a 1x2 table). There is a button in the flex app that, when clicked, sets the "src" property of the iframe to a URL by using the ExnternalInterface.call method to call a javascript function "doNavClick(url)". Or that's the idea. When I comment out the iframe obj...

Returning a byte string to ExternalInterface.call throws an error

I am working on my open source project Downloadify, and up until now it simply handles returning Strings in response to ExternalInterface.call commands. I am trying to put together a test case using JSZip and Downloadify together, the end result being that a Zip file is created dynamically in the browser, then saved to the disk using Fi...