(MX04) Pausing a loaded swf with sound objects within it

Hi,
I'm working on a PowerPoint-esque presentation where a user
watches and listens to a loaded swf in the main movie, clicks the
next button (which unloads the swf, advances to the next frame and
loads the next swf), and watches the next one. Lather, rinse,
repeat. Some of the sections are rather long, and I'd like to give
the user the ability to pause and play by button click.
I know how to stop and start the container MC, but that
doesn't stop the sound object (and the embedded MCs). I also know
how to pause and start a sound object using the object's instance
name. Is there a way to pause everything from the main timeline,
and keep the AS general enough so that any sound object pauses when
clicked?
Any help is most appreciated! MX04 and AS2.0.
Thanks!

Kglad,
I tried your code and ran into some problems with stopping
the mc's, as the embedded mc's within the loaded swf need to stop
as well. I found the attached code to stop the mc's, but now am
having trouble with the sound objects.
Here's the issue, I used this:
this.soundPosition = currentMovie.loop1.position/1000;
this.currentMovie.loop1.stop();
... for the sound object stop commands and listed a new one
for each loop I was using. On the play button I started them back
up again. This all works, but when I start them up again they all
play, not just the one that is currently paused. Do you mind giving
me some guidance with the for (obj in mc) loop? My loop experience
is nil. What I want to do is have the code cycle through all of the
loops to see which one is playing, then store that information in a
variable, then pause and play the variable. Does that sound right?
Thanks again for the help!
-Sandy

Similar Messages

  • Loading SWF with audio playing in it...

    I was loading a SWF file, and noticed that even if I didn't
    add it to the display via addChild() that I can hear the audio
    playing in it. Why is this? And likewise, when I do addChild(), and
    see the SWF, then later use removeChild(), and no longer see it, I
    can still hear it playing.
    I can sort of understand that even though it's not displayed
    until using addChild() that one would HEAR it, because it is loaded
    - correct? But how would I actually get rid of/delete this when I
    no longer want to see/hear it ?

    Thanks to the both of you! I'd like to see the things you do
    to "close up shop" on the loaded SWF.
    I also found something about getting access to your loaded
    SWF here:
    TextAccessing
    document class of an externally loaded swf with AS3
    That blog describes adding a generic object in the complete
    listener:
    var loaderInfo:LoaderInfo = e.target as LoaderInfo;
    var myLoadedSWF:Object = loaderInfo.content;
    You can then target myLoadedSWF and access your SWF. Seems
    pretty different than AS1 & 2, but I suppose that's how it is
    (unless there are better ways).

  • Controling a loaded swf with another loaded swf

    I have a blank stage with only AS that loads an swf
    addChildAt(0) and a second one addChildAt(1). This works. When the
    user interacts with (1) it calls another addChild (not indexed) and
    possibly that one loads another, depending on the choices made by
    the user. How can I get any of these to control that very first
    child that was loaded at (0)? I have run out of ideas.
    Some of the code:
    (on the main swf, nothing on the stage, only code that loads
    the next two)
    addChildAt(pHolder, 0);
    pLoader.load(pURLReq);
    pLoader.contentLoaderInfo.addEventListener(Event.COMPLETE,
    pLoaded);
    and for the second:
    addChildAt(mHolder, 1);
    mLoader.load(mURLReq);
    mLoader.contentLoaderInfo.addEventListener(Event.COMPLETE,
    mLoaded);
    On the child of childAt(1), I have:
    function replaceSWF(e:MouseEvent):void
    pLoader = new Loader();
    pLoader.load(new URLRequest("p.swf"));
    pLoader.contentLoaderInfo.addEventListener(Event.COMPLETE,
    placeNewClip);
    function placeNewClip(e:Event):void
    removeChildAt(0);
    addChildAt(e.target.content, 0);
    If I use this exact same code from that very first swf, the
    one that loads the first two external swfs, it works, but once I
    put it on one of hte other loadeds and sub loaded swfs, I can't get
    it to work. In the current state (0) it just makes everything on
    the stage disappear, so I figured then using the index of (1) would
    do it, but that or any other number results in absoluly nothing.
    Help! I am really out of ideas here.
    (the stacking looks like this) ---
    sub second loaded SWF <==== needs to tell first loaded SWF
    to unload then load a new swf at same index
    second loaded SWF <==== loads the next one above
    first loaded SWF <=== needs to be removed and another swf
    loaded at the same index
    mainSWF (loads two others) <=== code placed here works for
    first loaded SWF

    Kglad,
    I tried your code and ran into some problems with stopping
    the mc's, as the embedded mc's within the loaded swf need to stop
    as well. I found the attached code to stop the mc's, but now am
    having trouble with the sound objects.
    Here's the issue, I used this:
    this.soundPosition = currentMovie.loop1.position/1000;
    this.currentMovie.loop1.stop();
    ... for the sound object stop commands and listed a new one
    for each loop I was using. On the play button I started them back
    up again. This all works, but when I start them up again they all
    play, not just the one that is currently paused. Do you mind giving
    me some guidance with the for (obj in mc) loop? My loop experience
    is nil. What I want to do is have the code cycle through all of the
    loops to see which one is playing, then store that information in a
    variable, then pause and play the variable. Does that sound right?
    Thanks again for the help!
    -Sandy

  • How do I know when a file loaded into a Sound object is invalid?

    I'm writing an app that allows the user to play various sound files.
    Some of these files are mp3, but some may also be ogg, wma, etc.  The selection is out of my control, so I need the sound API to tell me if it can't play something.
    To test, I loaded some test files into a sound object like so:
                    var urlRequest:URLRequest = new URLRequest("http://support.microsoft.com/support/MediaPlayer/wmptest/samples/new/mediaexample.wma");
                    var sound:Sound = new Sound();
                    var soundChannel:SoundChannel = sound.play();
    Even though Flex doesn't play wma's there is no error information or null objects anywhere.  Everthings seems to be fine to flex, I can even register for progress events and see the wma being loaded.
    Just to see how far this goes, I loaded a gif instead of an audio file and the same thing happened.  Progress went fine with no errors of any kind even though I registered for every listed event.  As expected though, no sound played from the gif file.
    What is the recommended way for checking if a file is not playable?

    I'm looking more for an "is it playable" value (since it might be an FLA or FLV as well).
    Even a meaningful length value would work (for some reason duration is set to a value even when loading a gif file - not sure what it means for a GIF to have a length of 96 milliseconds).
    For now I'll have to filter on extension as you mentioned.

  • Loading swf into movieclip object

    I am trying to load a swf file into a movieclip object on the
    stage. The movieclip object is sized smaller than the screen, and
    placed in the middle. I have defined a loader with:
    var myMovieClipLoader:MovieClipLoader = new
    MovieClipLoader();
    then use it like this:
    _level0.myMovieClipLoader.loadClip("moviename.swf",
    _level5.movieclipinstancename);
    (the movieclip object is used in a swf loaded in level5)
    When I load the swf like this, the swf loads at the correct
    location according to where I have placed the movieclip object,
    however it "blows up" to fill the screen from that point down and
    across, ignoring the size of the movie clip object (the loading swf
    actually expands beyond it's created size to fill the screen,
    making all the graphics and text much larger than intended). The
    actual pixel size of the swf I'm trying to load matches the size of
    the movieclip object (1024x350 in a 1280x1024 screen).
    What is the magic setting or property that will tell the
    loading swf to honor the size of the movieclip object I'm loading
    into?
    Thanks for your help!
    Barb

    Something I've been working on:
    Place the following code in a new file <your project
    folder>\as\MovieContainer.as
    Then open the properties for the symbol you want to be your
    movie container
    Set the AS 2.0 Class to as.MovieContainer and give it a name
    (I named mine 'loader').
    To load the movie, simply call:
    loader.queueSWF('my.swf');
    Hope that makes sense. Basically, it's just a self contained
    class for loading into an object on the scene. It draws a simple
    progress bar on the center of the symbol when it's loading and it
    resizes the loaded object on init to conform to the size of the
    object on the stage. Why queueSWF? Well, if it's currently loading
    a SWF, it will wait till it's finished and load a new one. The
    biggest problem right now is the progress bar, but it's fairly easy
    to remove if you don't like it. Hopefully it helps.
    If anyone else is reading this. I'm trying to figure out if I
    can load these movies into an array of movieclips. So far I've had
    no luck. If you know of a way, feel free to drop some input.

  • DMP 4310 load swf with flashvars

    Hi,
    I am using dmp 4310 and i want to load a swf file using flashvars. This swf is loaded through another swf (a wrapper swf) with the "MovieClip Loader Object" (AS2). When i load the swf using http request i do not have any prblems (eg clipLoader.loadMovie("http://10.0.0.1/swfTest.swf?flashVar1=test1")). The problem is that i cannot get the flashvars by loading the same swf file locally (eg clipLoader.loadMovie("file:///tmp/ftproot/usb_1/files/swfTest.swf?flashVar1=test1")). Is there any way to get the flashvar? Also, is there any way to access the swf file (with the flashvars) using the internal http service (eg http://localhost/...swfTest.swf?flasvar1=test1  -- where localhost is the player itself).
    Thank you in advance for your response!

    Suddenly that code in the following gives me some error
    var langPath = root.LoaderInfo.parameters["xmlFilePath"]+root.LoaderInfo.parameters["lang"];
    my_ssp.xmlFilePath = langPath;
    var fileType = root.LoaderInfo.parameters["xmlFileType"];
    my_ssp.xmlFileType = fileType;
    Access of possibly undefined property LoaderInfo through a reference with static type flash.display:DisplayObject.
    The only code snippet works is
    var paramObj:Object = LoaderInfo(this.root.loaderInfo).parameters;
    for (var param in paramObj) {
       if (param == "xmlFilePath") {
          my_ssp.xmlFilePath = paramObj[param];
       if (param == "xmlFileType") {
          my_ssp.xmlFileType = paramObj[param];

  • Loaded movie with sound problem

    I have some movies with attached sound. The movie uses the
    sound position property and preset cue times to drive action in the
    movie. They play fine on their own but when they are loaded into
    another movie using either loadMovie or loadMovieNum, the sound
    does not play and the cue driven action don't work. I made sure to
    set the _lockroot property to true in the loading clip with
    loadMovie and also put it in the original movie and tried using
    loadMovieNum.
    What happened to the sound?

    when instantiating your sound object try:

  • Play flv with Sound object

    How can I play a flv file, stored on my file system
    (C:\Program Files\Macromedia\Flash Media Server
    2\applications\my_app\streams\_definst_\File1.flv) play with the
    Sound object?
    Any help greatly appreciated.

    blurrymurry wrote:
    > your right !
    > thanks flashtard your the tardiest!
    > I thought the variable name was good enough, but forgot
    to include the linkage
    > id in the stop button. so that it would only stop the
    specified sound.
    > So much to learn
    > Hey how does one go about becoming a news group member
    so that other forum
    > users think I'm cool. Is there a point in this or do
    they just get mad at all
    > the newbie questions?
    In regards to News Group users.
    The news server was the very first thing set up almost decade
    ago by macromedia
    for all their products as user-to-user support. Web based
    forum is a very new
    addition and it's not properly synchronized. Many of use
    remain using news server
    because it's much faster to load the messages, there are no
    pages to flip through,
    all the topic and replies follow by the order they appear and
    generally, it's much
    faster to search the forum than using the web based interface
    and lots and
    lots more pros in using that. Not all users however have the
    access to news servers
    so the web based forum is to allow anyone to get help when
    comes to Adobe/Macromedia
    tools.
    If you run programs like Outlook or Thunderbird (like myself
    here) for you emails, you
    can easily add/access the news server by setting up new
    Newsgroup Account.
    The server is forums.macromedia.com , once you there you can
    get list of all the other
    servers and subscribe to any one you need.
    Best Regards
    Urami
    !!!!!!! Merry Christmas !!!!!!!
    <urami>
    If you want to mail me - DO NOT LAUGH AT MY ADDRESS
    </urami>

  • Out of memmory with Sound object

    Hello,
    I have 2k+ of mp3 files and i need form playlist based on id3 tags. When i create air.Sound object in JS I run load() method and get ID3 tags in COMPLETE event handler. After that i create new Sound object for next file and all looks fine but near 900 file I get Out of memmory error. Whats wrong?
    Before create new object I set old variable value to NULL.

    Below is my basic code. I can convert it into something even more bare if needed. Basically I scan the hard drive for mp3 and AAC's, then pass the file object to this class to get the id3 tags. I've tried deleting sound, setting it to null, but no matter what I seem to have the song sticking in memory. It seems to be about 8MB of RAM for each sound object opened.
    NX.Sound = Class.create(,
         getId3Object: function(file, onComplete){
              var urlRequest = new air.URLRequest(file.url);                    
              var soundLoaderContext = new air.SoundLoaderContext(0, false);     
              var sound = new air.Sound();
              sound.addEventListener(air.Event.ID3, function(e){           
                var id3 = air.Sound(e.currentTarget).id3;
                id3.path = file.url;
                id3.title = id3.TIT2;
                id3.artist = id3.TPE1;
                sound.close();
                      onComplete(id3);
              sound.load(urlRequest, soundLoaderContext);

  • AIR crashes on loading swf with 'Imported for runtime sharing' fonts

    Hello everybody,
    I have a trouble with an AIR application developped with Flex but the error seems to come from the Flash/AIR, after some searches a staff member (Flex harUI) said me that I could find more help for my trouble here.
    I'm developping an AIR application which loads an external swf. This swf contains 'Imported for runtime sharing' fonts from another swf to reduce its size.
    When the AIR application has finished to load (see message below) the whole application crashes without giving any error message except the usual "Process terminated unexpectedly" error message.
    End Loading: [SWF] C:\Users\dev02\myProject\index.swf - 83,930 bytes after decompression
    Error Message:
    Process terminated unexpectedly.
    Launch command details:  "C:\Program Files (x86)\Adobe\Adobe Flash Builder 4\sdks\4.6.0\bin\adl.exe" -runtime "C:\Program Files (x86)\Adobe\Adobe Flash Builder 4\sdks\4.6.0\runtimes\air\win" "C:\Users\dev02\Adobe Flash Builder 4\Languages_Editor\bin-debug\Language_Editor-app.xml" "C:\Users\dev02\Adobe Flash Builder 4\Languages_Editor\bin-debug"
    I use Flash Builder 4 (build 272416) with sdk 4.6.
    Full discussion here.
    I tried to load the external swf with the most basics codes, it works with a Flash web app but not with a Flex/AIR app or a Flash/AIR app.
    Thanks for the help !

    Thanks for the anwser.
    In fact, I cannot specify a swc because my main application is an editor of sub-applications where each one has its own library.
    The bug remains when sharing a simple MovieClip too.
    Maybe, if I explain my project it will be a little more clear.
    I'm developping a multi-languages module / application.
    For each module, I have an external xml for texts. So in order to add a new language we don't need to recompile, just to change texts in the xml. But, I had to externalize my fonts, (imagine if each swf contains the whole characters set like latin, cyrillic, etc.).
    And then, I have my main text editor application above the module, which loads texts xmls and a preview of the page where we need to change the text. (This is where it crashes, during the process of loading the preview).
    My editor works great for translating, changing texts, modify images but without the preview, what is really frustrating.
    (not so ergonomic, I know...)
    I hope it will help you to understand my trouble.
    regards

  • SQL Loader Constraints with Column Objects and Nested Tables

    I am working on loading a Table that (god forbid) contains columns, column objects, and nested tables (which contains several depth of column objects). My question is does SQL Loader have a hidding undocumented feature where it states how the column objects must be grouped in refereneced to the nested tables within the loader file? I can load the various column objects, and nested tables fine right now, however, I am loading them all in strange and insane order. Can anyone answer this question? Thanks.
    Peter

    I just noticed that my email is wrong. If you can help, plese send email to [email protected]
    thanks.

  • Load SWF with instances into MC

    Hello,
    I have a SWF called "player.swf", and it contains instances
    like: "head", "body" etc...
    I want to load that SWF into another SWF
    ("display_player.swf"), and to load ANOTHER SWF to replace the
    "head" instance, like:
    "_root.p" is a transparent red colored movie clip inside
    "display_player.swf"
    I tried doing this:
    _root.p.loadMovie("player.swf");
    trace(_root.p.head);
    "_root.p" said to be "_level0.p" and is displayed correctly,
    but "_root.p.head" said to be undefined (NaN)...
    Does anyone has an idea on how to load a SWF inside a movie
    clip, and use it's instances?

    The point here is to demostrate, or at least determine, what
    the problem is. I have stated that it is probably likely that you
    are making the call to _root.p.head previous to it being
    instatiated on the timeline. you must wait for the swf to load
    before the clip within the loaded swf can be made available to
    target. A better method would be to use the MovieClipLoader class,
    and then use the onLoadInit handler, this handler is displatched
    when the swf becomes available to the timeline, then within the
    handler you could call your trace, or load into the 'head' instance
    at the correct time.
    I have made an example to demostrate this, using
    representations of you clips and swfs:
    HERE
    PS. launch the items from within the folder.

  • Loading a swf with sound... now I can't stop the sound.

    I have an mp3 player that works standalone. When I load it
    into another
    movie I do it like so...
    musicHolder.sound_holder.removeMovieClip();
    musicHolder.createEmptyMovieClip("sound_holder", 29);
    musicHolder.sound_holder.loadMovie("radio/mp3player.swf",
    "GET");
    This works great, and the player loads and plays and all is
    great and
    wonderful. But now I want to close the player. If I do a
    removeMovieClip
    like this:
    musicHolder.sould_holder.removeMovieClip();
    Then the viual of the MC goes away, but not the sound. Is
    this because the
    sound is somehow loading into the _root timeline of the main
    movie loading
    the mp3player.swf?
    Please, a little help.
    acb

    this is inelegant but should work,
    musicHolder.sould_holder.removeMovieClip();
    stopAllSounds();

  • Loading swf with XML on Click

    Hi all, can anyone help
    can anyone shine a little light onto a little confusion I am having, I have a menu that already loads in images via an XML file on a menu, what I am trying to do is when an image/meni Item is click I would like to load in an swf into the same place as the image Item loads into! am I making any sense.
    on a click event, do I use in the XML file the <link>link to swf</link>   ????
    this is what I have in my xml file that loads in the images so far;
    <image name="image 12" path="img/img12.jpg"
    title="Lorem ipsum 12"
    text="Lorem ipsum dolor sit amet, consectetuer adipiscing elit. Morbi commodo 12" />
    what I am getting confused with is what I also put within the AS, I am sure it is not alot but I'm just not sure what needs to go where??
    this is what I have within the AS that loads in XML, I hope its ok to paste this code, never like posting to much code incase is scares people off, I just don't want to leave anything out, hope thats ok with everyone:eek:
    // Use URLLoader to load XML
    xmlLoader = new URLLoader();
    xmlLoader.dataFormat = URLLoaderDataFormat.TEXT;
    // Listen for the complete event
    xmlLoader.addEventListener(Event.COMPLETE, onXMLComplete);
    xmlLoader.load(new URLRequest("data.xml")); 
    stage.addEventListener( MouseEvent.MOUSE_WHEEL, onMouseWheel );
    //———————————————EVENT HANDLERS
    private function onXMLComplete(event:Event):void
    // Create an XML Object from loaded data
    var data:XML = new XML(xmlLoader.data);
    // Now we can parse it
    var images:XMLList = data.image;
    for(var i:int = 0; i < images.length(); i++)
    // Get info from XML node
    var imageName:String = images[i].@name;
    var imagePath:String = images[i].@path;
    var titles:String = images[i].@title;
    var texts:String = images[i].@text;
    // Load images using standard Loader
    var loader:Loader = new Loader();
    // Listen for complete so we can center the image
    loader.contentLoaderInfo.addEventListener(Event.COMPLETE,onImageComplete);
    loader.load(new URLRequest(imagePath));
    // Create a container for the loader (image)
    var holder:MovieClip = new MovieClip();
    holder.addChild(loader);
    var button_main:Button_mr = new Button_mr();   /
    holder.addChild(button_main);               
    var tooltip:ToolTip = new ToolTip();
    tooltip.field.text = titles;  //loads tooltip 1
    tooltip.field2.text = texts;  //loads tool tip 2
    tooltip.x = -350; 
    tooltip.y = 0;   
    holder.addChild(tooltip);
    // Same proceedure as before
    holder.buttonMode = true;
    holder.addEventListener( MouseEvent.CLICK, onMenuItemClick );
    // Add it to the menu
    circleMenu.addChild(holder);
    many thanks for any help!!!!

    1. Be sure in main.swf there is no masking or layering hiding
    the reflection area. A way to test quickly is to load in a plain
    master swf that is much larger than the externals swf.
    2. Know the weakness of loadMovie for timing issues that
    require the external movie to be fully loaded before actions are
    taken on it. I see a bunch of these in the code you posted. Best to
    use
    MovieClipLoader.onLoadInit
    before you attempt to access the external swf properties or code or
    add code.
    3. Be sure the code is firing on load and all objects are
    created. Add some trace statements for those objects.
    4. I noticed you do not use BitmapData so this may not be
    relevant but be sure to add
    System.security.allowDomain("*");
    to the main.swf as well as in external swfs and only if you
    are using the BitmapData class.
    5. As I started to look at the code a bit and noticed this
    item:
    There is no constructor for the Flash MovieClip class. You
    will not see a compiler error message because you do not have the
    code wrapped into a class.
    var home:MovieClip = new MovieClip();
    However it does not have impact on the code.
    better would be
    var home:MovieClip;

  • Loaded swf with button , not communicating to main timeline

    my main stage/timeline has a UILoader "UILoaderOne" and
    another one "UIloaderTwo".
    i have some buttons on the main stage which pull up some
    images into the UILoaderOne.
    these work fine and look like this.
    //BEGIN BUTTONCODE\\
    //button to load image into loader "loaderOne" x01_btn and
    x01_ldr, thumb image is "x01.jpg and main image is p01.jpg\\
    //crop thumb image to size 50px tall by whatever wide and
    resize loaderButton if needed, main image will resize
    proportionatly\\
    x01_btn.addEventListener(MouseEvent.CLICK, onClick);
    function onClick(event:MouseEvent):void
    //import fl.containers.UILoader;
    import fl.controls.Label;
    import fl.controls.ProgressBar;
    var url:String = "assets/01.jpg";
    //var myUILoader:UILoader //= new UILoader();
    myUILoader.unload();
    myUILoader.autoLoad = false;
    myUILoader.source = url;
    //myUILoader.move(10, 10);
    myUILoader.scaleContent = true;
    myUILoader.load();
    var myProgressBar:ProgressBar = new ProgressBar();
    myProgressBar.source = myUILoader;
    myProgressBar.setSize(100, 10);
    myProgressBar.move(myUILoader.x+340, myUILoader.y+250)
    myProgressBar.addEventListener(ProgressEvent.PROGRESS,
    progressHandler);
    myProgressBar.addEventListener(Event.COMPLETE,
    completeHandler);
    addChild(myProgressBar)
    var myLabel:Label = new Label();
    myLabel.text = ". . . . . X . . . . . ";
    myLabel.autoSize = TextFieldAutoSize.LEFT;
    myLabel.move(myProgressBar.x, myProgressBar.y +
    myProgressBar.height);
    addChild(myLabel);
    function progressHandler(event:ProgressEvent):void {
    //trace("progress:", event.bytesLoaded, event.bytesTotal,
    int(event.currentTarget.percentComplete) + "%");
    //myLabel.text = event.bytesLoaded + " of " +
    event.bytesTotal + " bytes loaded.";
    myLabel.text = ("progress:", event.bytesLoaded,
    event.bytesTotal, int(event.currentTarget.percentComplete) + "%")
    //myLabel.text =
    Math.round((event.bytesLoaded/event.bytesTotal)*100) +"%";
    function completeHandler(event:Event):void {
    trace("complete:");
    myProgressBar.removeEventListener(ProgressEvent.PROGRESS,
    progressHandler);
    myProgressBar.removeEventListener(Event.COMPLETE,
    completeHandler);
    removeChild(myProgressBar);
    removeChild(myLabel);
    //addChild(myUILoader);
    //trace("typeMe");
    //end BUTTONCODE\\
    //end BUTTONCODE\\
    the second Loader "UILoaderTwo" auto loads another swf file
    with the INTENT to load from buttons, images into the ULLoader
    "UILoaderOne" which is on the main timeline.
    this part is failing
    the error i get in Output window is
    TypeError: Error #1009: Cannot access a property or method of
    a null object reference.
    at sOne_fla::MainTimeline/onClickz()
    the swf that loads is sOne.swf
    and it has code of this
    z01_btn.addEventListener(MouseEvent.CLICK, onClickz);
    function onClickz(event:MouseEvent):void
    import fl.containers.UILoader;
    import fl.controls.Label;
    import fl.controls.ProgressBar;
    var url:String = "assets/xx.jpg";
    var myUILoader:UILoader //= new UILoader();
    myUILoader.unload();
    myUILoader.autoLoad = false;
    myUILoader.source = url;
    //myUILoader.move(10, 10);
    myUILoader.scaleContent = true;
    myUILoader.load();
    var myProgressBar:ProgressBar = new ProgressBar();
    myProgressBar.source = myUILoader;
    myProgressBar.setSize(100, 10);
    myProgressBar.move(myUILoader.x+340, myUILoader.y+250)
    myProgressBar.addEventListener(ProgressEvent.PROGRESS,
    progressHandler);
    myProgressBar.addEventListener(Event.COMPLETE,
    completeHandler);
    addChild(myProgressBar)
    var myLabel:Label = new Label();
    myLabel.text = ". . . . . X . . . . . ";
    myLabel.autoSize = TextFieldAutoSize.LEFT;
    myLabel.move(myProgressBar.x, myProgressBar.y +
    myProgressBar.height);
    addChild(myLabel);
    function progressHandler(event:ProgressEvent):void {
    //trace("progress:", event.bytesLoaded, event.bytesTotal,
    int(event.currentTarget.percentComplete) + "%");
    //myLabel.text = event.bytesLoaded + " of " +
    event.bytesTotal + " bytes loaded.";
    myLabel.text = ("progress:", event.bytesLoaded,
    event.bytesTotal, int(event.currentTarget.percentComplete) + "%")
    //myLabel.text =
    Math.round((event.bytesLoaded/event.bytesTotal)*100) +"%";
    function completeHandler(event:Event):void {
    trace("complete:");
    myProgressBar.removeEventListener(ProgressEvent.PROGRESS,
    progressHandler);
    myProgressBar.removeEventListener(Event.COMPLETE,
    completeHandler);
    removeChild(myProgressBar);
    removeChild(myLabel);
    //addChild(myUILoader);
    //trace("typeMe");
    //end BUTTONCODE\\
    //end BUTTONCODE\\

    well, I'm such a novice to begin with.
    the loader is actually placed on stage manually, and instance
    named manually so a lot of that code is may not be needed,
    i do a lot of trial and error technique
    it is all personal stuff
    one guess i have is to set up a listner as to when the sOne
    is loaded, and then get a way to communicate to each other?
    how?

Maybe you are looking for

  • Open inbox instance in same window

    In 6.0.x. when a instance in the workspace inbox is clicked, it opens in a new window, but in 5.7 it opens on the same page, is there any way to make the inbox instance open in the same window (html page).

  • "What Size" results question. How can I locate used GB not appearing on HD?

    My Version Tracker "What Size" results are as follows: / - on disk 91.4 GB Capacity 465 GB Used 145 GB Available 320 GB 71.1 GB Users 8.61 GB Applications 6.34 GB Library 2.67 GB username 1.43 GB System I have about 30 GB of songs, 5 GB of Pictures,

  • Validate user input

    How do I validate the data that the user inputs through the prompts? Example: End date is not earlier than start date, or End Date - Start Date <= 12 months? Any direction is appreciated

  • RMAN logical backup containing unused blocks

    Dear Experts When i taking logical backup of datafile from RMAN utility i notify that it will also backed up all unused blocks from datafile, so what i need to do, how to avoid that unused block from being backed up while taking logical backup of dat

  • Finally landed my first IT job with an MSP! What to expect?

    For the first few months and depending on the amount of customers you support, expect a decent size learning curve in becoming familiar with their tech. Also expect that the customers will take some time to get used to you, especially if they are use