actionscript 3 - Android AIR AS3 Class - Error 1046 -


i have admob code in class file:

package {     import flash.events.mouseevent;     import flash.display.movieclip;     import flash.system.system;     import flash.system.capabilities;     import flash.display.sprite;     import flash.events.event;     import flash.desktop.nativeapplication;     import flash.utils.settimeout;      import com.hdi.nativeextensions.nativeads;     import com.hdi.nativeextensions.nativeadsevent;      ......................the code continues 

...and @ end of timeline have as3 code loading swf file:

var _swfloader:loader; var _swfcontent:movieclip;  loadswf("maina.swf");  function loadswf(path:string):void {    var _req:urlrequest = new urlrequest();    _req.url = path;     _swfloader = new loader();    setuplisteners(_swfloader.contentloaderinfo);     _swfloader.load(_req); }  function setuplisteners(dispatcher:ieventdispatcher):void {    dispatcher.addeventlistener(event.complete, addswf);    dispatcher.addeventlistener(progressevent.progress, preloadswf); }  function preloadswf(event:progressevent):void {    var _perc:int = (event.bytesloaded / event.bytestotal) * 100;    // swfpreloader.percenttf.text = _perc + "%"; }  function addswf(event:event):void {    event.target.removeeventlistener(event.complete, addswf);    event.target.removeeventlistener(progressevent.progress, preloadswf);     _swfcontent = event.target.content;    _swfcontent.addeventlistener("close", unloadswf);     addchild(_swfcontent); }  function unloadswf(event:event):void {    _swfloader.unloadandstop();  removechild(_swfcontent);    _swfcontent = null; } 

...but there problem , can't seem able fix it... get: 1046: type not found or not compile-time constant: ieventdispatcher. , 1046: type not found or not compile-time constant: progressevent.

but if ad ieventdispatscher import in class file, other errors... can me? wouldn't mind changing entire loading swf code...

thanx!


Comments

Popular posts from this blog

php - Wordpress website dashboard page or post editor content is not showing but front end data is showing properly -

How to get the ip address of VM and use it to configure SSH connection dynamically in Ansible -

javascript - Get parameter of GET request -