flex端

   public function initApp():void
   {
    ExternalInterface.addCallback("function1",callback1);
   }
   
   public function callback1():void
   {
    Alert.show("hello word");
   }

js端

 function JavaScript()
     {  
         document.getElementById("Dome1").function1();
     } 

    <object class  /> 

 注意:如果flex程序里面调用了外部的图片或者视频等文件时,一定要把路径跟flex中调用的路径统一起来

相关文章:

  • 2022-12-23
  • 2022-12-23
  • 2021-07-05
  • 2022-12-23
  • 2021-10-09
  • 2021-05-21
  • 2022-12-23
  • 2021-09-02
猜你喜欢
  • 2021-12-21
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2021-04-24
  • 2022-12-23
相关资源
相似解决方案