how to detect loaded SWF width?

Ask a Question related to Macromedia Flash Actionscript, Design and Development.

  1. #1

    Default how to detect loaded SWF width?

    Using MX 2004 I have loaded an external SWF like this:

    _root.createEmptyMovieClip("screenSaver", _root.getNextHighestDepth() );
    _root.screenSaver.loadMovie("screensaver.swf");

    which works fine, but why does "_root.screenSaver._width;" return 0?
    How can I detect the width of the loaded SWF?

    Thanks!

    mike2020 Guest

  2. Similar Questions and Discussions

    1. I know we can set max image width, but I need to set itby region. Region A has one max width; Region B another.
      We can already set a maximum image width for use globally, throughout every page. Can we do it by region? This way one region can have a max...
    2. DG Column Width vs Table Column Width
      Hi, I am wanting to display data in a datagrid with additional header rows above it that categorise some of the main headers of the datagrid. I...
    3. Detect frame number from loaded movie...
      Hello... I have my main movie that loads another small movie into it. IŽll call it (movie2)...How can i detect using my main movie that the...
    4. #26240 [Opn->Bgs]: Functions of XSL-extension didn't loaded, however itself extension was loaded.
      ID: 26240 Updated by: chregu@php.net Reported By: igor_udintsev at mail dot ru -Status: Open +Status: ...
    5. #26240 [NEW]: Functions of XSL-extension didn't loaded, however itself extension was loaded.
      From: igor_udintsev at mail dot ru Operating system: Linux Red Hat 9 PHP version: 5.0.0b2 (beta2) PHP Bug Type: XSLT related...
  3. #2

    Default Re: how to detect loaded SWF width?

    The script is fine but you have to wait until 'screensaver.swf' has been
    loaded. Then you can refer to it.
    It returns 'cause it has not been loaded yet and the _width of the mc you
    create ("screeSaver") is 0.

    HTH,

    -c.

    CesareRocchi Guest

  4. #3

    Default Re: how to detect loaded SWF width?

    that explains it!

    thank you
    mike2020 Guest

Posting Permissions

  • You may not post new threads
  • You may post replies
  • You may not post attachments
  • You may not edit your posts

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139