I think you are opening the swf file which doesn`t have the javascript function.Try opening the html file which has javascript the swf file wrapped inside .
On Tue, Dec 9, 2008 at 2:52 PM, koteshwar Rao myneni <[EMAIL PROTECTED]> wrote: > > > Hi all, > i am calling javascript function from action script ,,,, but i am get > the #2060 error > any help ... > ======================================= > <?xml version="1.0" encoding="utf-8"?> > <mx:Application xmlns:mx="http://www.adobe.com/2006/mxml" > layout="absolute"> > <mx:Script> > <![CDATA[ > public function callfun():void{ > > ExternalInterface.call("javascriptfunction"); > } > ]]> > </mx:Script> > > <mx:Button click="callfun()"/> > </mx:Application> > > ==================================== > <script type="text/javascript"> > function javascriptfunction() > { > alert("Hello World! from javascript "); > } > > </script> > > ================================== > SecurityError: Error #2060: Security sandbox violation: > ExternalInterface caller file:///C:/Documents and Settings/myneni/ > Desktop/testttttt/tt.swf cannot access file:///C:/Documents and > Settings/myneni/Desktop/testttttt/tt.html. > at flash.external::ExternalInterface$/ > flash.external:ExternalInterface::_initJS() > at flash.external::ExternalInterface$/call() > at tt/callfun() > at tt/___tt_Button1_click() > > > --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Flex India Community" group. To post to this group, send email to [email protected] To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/flex_india?hl=en -~----------~----~----~----~------~----~------~--~---

