Hi,

Background:
- a given folder
- many pictures in the folder (D1.jpg, D2.jpg, etc...screenshots genre)

Goal:
- automate the embedding of the pictures at compile time (for info, the
future SWF will latter show synchronised screenshots with an audio
recording)

Newbie problem:
- I know how to do it "by hand" (see below)
- I don't see how I can "automate" the embedding of the pictures, ie:

By hand (I search for an AS3 solution for now, UIcomponent gave me problems
while trying to find a Flex solution):

~
"""
package
{
    import flash.display.Sprite;

    public class Main extends Sprite {

        private var screenshots:Array = new Array(); // screenshots
instances array

        [Embed("../assets/screenshots/D1.jpg")]    // how do I automate
that?
        private var Screen1:Class;                         // how do I
automate that?
        [Embed("../assets/screenshots/D2.jpg")]    // how do I automate
that?
        private var Screen2:Class;                         // how do I
automate that?

        public function Main() {

            screenshots.push(new Screen1()); // populate the screenshots
array
            screenshots.push(new Screen2());
            addChild(screenshots[0]);              // show the screenshots
            addChild(screenshots[1]);
        }
  }

}
"""

If we know that in the given folder there is let say 30 screenshots, how do
I automate the embedding of this pictures in the script above ? (or a Flex
alternative? a URL, suggestion, etc)

Thanks

Reply via email to