How can I get the width of a loaded swf scene?

Is it possible to get the real of a loaded swf stageWidth?

The problem comes when the loaded swf file has some items off the stage. In this case content.width becomes bigger then the scene.

My code looks like this:

var request: URLRequest = new URLRequest (file.url);

var loader: Loader = new Loader();

Loader.Load (request);

loader.contentLoaderInfo.addEventListener (Event.INIT, CaseTailleAuto);

loader.contentLoaderInfo.addEventListener (Event.COMPLETE, addImg);

private void checkSize(e:Event) {}


That's where I need to see the width of my loaded swf

trace (e.Target.Content.Width);

}

private void addImg(e:Event) {}

trace ("complete");

}

Thank you

Andrei

I don't think you can get the width of the stage of the loaded file, unless you assign it as a constant somewhere in the file.  The loaded file loses its stage when it is loaded into another swf

Tags: Adobe Animate

Similar Questions

Maybe you are looking for

  • Re: Satellite A65-S1067 - display driver does not work

    As stated in my title, the display (ATI Radeon 7000 IGP) on my Toshiba laptop driver does not work and has not worked for quite a while. Whenever I try to play a game that is to install a game (like World of Warcraft or Civilization III) it does not

  • late

    Why Apple is so late, just got an iPhone 5SE and I can't pair it with my macbook pro via Bluetooth, I can't believe its that poor.  You wait at least Apple products to pair each plus, if not to some third-party products. Anyone have an idea how I can

  • Vista does not recognize the product key

    I reinstalled Vista using the disc of recovery of the product due to unrecoverable corruption. Once installed Vista indicates that the OS is not authentic and that she invites you for an alternative. I also entered the product key from the sticker on

  • Repetition of Windows updates

    I constantly receive alerts of update for the same updates even if I downloaded and installed the. I looked in Add/Remove programs and updates do not appear in the list of other updates. I can't assume these updates are not install properly although

  • Removing a card table / placed on a document

    I must have accidentally hit a button that produces a table on my typed document and I can't delete the chart. Save as something else does not work and does not even open a new document and upload it.  Now, any doc that I opened is projecting a card