CreateEmptyMovieClip creates it on all frames (AS2)?

Hey everyone,
I have a question regarding createEmptyMovieClip in AS2. I have a flash file separated out into sections with labels and menu buttons which allow you to move you to the relevant frame/section (which contains the information/contents relevant to that section). This works fine. What I can't work out is that if I manually put a movieclip on the stage in my 'about section' and then add contents to it via AS2 then it only exists within the about us section. If I do it using createEmptyMovieClip within the actions for the about frame this works fine but it then always exists on every other frame of the project. I assume this is because it isn't actually creating it within this frame but I can't work out how to make it do this, even when i use this.createEmptyMovieClip it has exactly the same effect. I can obviously remove the movieclip completely each time a user moves to another frame that doesn't contain it but I don't want to do this as it contains a youtube video and leaving it means it doesn't have to be reloaded each time they come back.
I would be massively grateful if anyone could shed any light on this for me as I know i'm not getting how to place it correctly but i'm not sure how I should be doing it?
Thanks so much in advance,
Dave

Hi Ned,
Thank you so much for your response, which was extremely clear as ever, that makes perfect sense and i understand the logic now so thank you! One follow up question, i have created an empty mc manually on the stage as you suggested and have created my mc via as2 within it. This works fine and now it only shows up when within the about us section. I am using the YouTube AS2 API to embed a youtube video within this movieclip, the start of this code (to create the mc) is:
var ytplayer:MovieClip = createEmptyMovieClip("ytplayer", 1);
As a result I have just changed it to the following (where video_mc is the instance name of the movieclip i manually put on the stage):
var ytplayer:MovieClip = video_mc.createEmptyMovieClip("ytplayer", 1);
This is great and works fine however prior to this I need to check for the existence of the movieclip so I could see whether to recreate it or not. I was using:
if (!ytplayer){
to check for it's existence which worked fine, however with the new code I thought the following code should be used but it does not seem to work:
if (!video_mc.ytplayer){
Similarly, I suspect it's the same problem with the following code (i'm using it when navigating to another section to stop it from playing as the audio continues to play even though the player disappears):
ytplayer.pauseVideo(); // This works fine when using the original code
video_mc.ytplayer.pauseVideo(); // This doesnt work
I think these are probably both the same issue and that I should be referencing it in a different way (and not video_mc.ytplayer), but I can't work out what and nothing i try seems to work. If you could shed any light on these remaining issues in then that would be massively appreciated as i'm rather confused!
Thank you so much for your help as ever,
Dave

Similar Messages

  • Changing the titles of all frames in a running application

    Hi All,
    I've got a 50+ frame application. I have realized that I need to update the frame titles for all the frames based upon some event that can be initiated by any of the frames. Each frame title will be different but will incorporate a bit of knowledge about the event. (Note that when I use the term "event", I'm using it in the normal English language sense, not a Java language sense!)
    I've been considering a few approaches and most look either stupid or a whole lotta' work! I'm looking for how to do this the "right way." ...I don't have a broad enough experience to know what's "common" regarding application architecture, but here's what I've got:
    A "Master" class kicks things off. It instantiates a few things like a database connection and so forth, and then it starts a MainFrame that appears on the users screen. The MainFrame, and all of its children, are actually of a class that's an extension of JFrame.
    It's my supposition that I'd like to create some kind of frame pointer holder in the Master, and all frames "register" themselves. When an event occurrs that warrants changing the frame titles, the Master walks the collected frame pointers and directs the titles be changed, as appropriate. ...OR... Is there already a collection of "children" of the master? How would I get that list and how would I walk it looking for a frame?
    Another idea is to be able to send some kind of notification to each frame and say, "Go Update Your Title!"
    Example code GREATLY appreciated!
    Thanks much,
    Richard

    ... While looking into doing this EventObject thing, I noticed that EventObjects are a heavyweight version of what I want... What it really boils down to is:
    Master defines:
    private static Master M = null;
    Vector myChildren = new Vector();
    Then in the constructor:
    M = this;
    Then in a method:
    Vector v = (Vector)myChildren.clone;
    for (int i=0; i<v.size(); i++;)
    ((JFrame)v.elementAt(i)).updateTitle();
    In each JFrame (in my case, in the class that extends JFrame):
    M.addElement(this);
    and in the right place
    M.removeElement(this);
    Oh yeah, and don't forget a method to set the frame title!...
    public void updateTitle()
    this.setTitle("whatever");
    ...That's it! WAY easier than all that foolishness with declairing your own event listeners and everything... For my needs, this was the way to go!
    Regards,
    Richard

  • Creating Animated GIF using Frames

    I would like to create an animated gif without using the 'tween' tool. Basically, I'd like to have an object move across the screen, stop at one point, perform a task (i.e., move arms/legs up and down in a 'jumping jack' style) and then continue on across the screen. I create the first frame then click on the 'duplicate frame' icon. In this frame I use the puppet warp feature to change the position of my object's arms/legs. Next, I duplicate the frame again and repeat the puppet warp process. Finally, I continue to duplicate the frames, moving the object 'x' spaces each frame until it finishes its journey across the screen.
    Unfortunately, when I change the position of my object's legs/arms, it changes all of them across all frames. However, the program still allows the object to continue its journey across the screen.
    Because of this, I have had to create separate jpg files for each and every one of the object position changes, then import each one with the 'place' tool into the layers and finally create frames from layers and save the gif that way.
    Is there a way to do the above without having to create a separate jpg for each one?

    Hi SweetFang,
    If you're using the Puppet Warp tool, I may suggest you change your workflow. When you duplicate a frame, it doesn't necessarily duplicate the object that is being animated so each change you make will show up in every frame. Instead of duplicating frames to make your changes, try duplicating layers. It will be a good deal easier than saving out a .jpg for each image and then placing them in.
    1. Create your background.
    2. Create a new layer for the object you will animate. Position it how you want it to look in the first frame of your animation.
    3. Now, duplicate the layer and use the puppet transform tool to make your first change.
    4. Repeat this process: duplicate your most recent layer, make your change, duplicate your most recent layer, make your change, etc. (To keep your workspace clear you may want to make each previous layer invisible when you add a new one)
    5. When you're completely finished, open your Animation panel (CS5) or Timeline panel (CS6) and in the flyout menu, choose Make Frames From Layers
    This workflow is essentially what you're doing already, but you're duplicating layers instead of frames and then making the frames automatically.
    Please let me know if this makes your project a little bit smoother.
    Cheers,
    Michael

  • Add static background image to all frames of gif animation

    First, I'm not a fireworks regular. I use it when I have to to get something done (mostly web optimazations). I would use it more but, frankly in many cases the UI is counter intuitive to everything else adobe makes.
    Here is my problem...
    I need to add (not replace) a static background to ALL existing frames(states) in a fireworks gif animation (with alpha) , the end product gif will be an element in the Edge web animation...details
    I have an animated seq of a rotating object that was created in 3ds max and rendered as a png seq with alpha.
    I opened the SEQ "as animation" in fireworks. I set the frame rate. It plays fine. So far so good....
    I imported an image that I want to be BEHIND the animated seq on ALL frames. I tried puting it on a sub layer behind, i tried puting it on it's own layer behind, but it ONLY shows on the first frame (state).
    I tried using "share with all states" but it replaces the SEQ images already on the "states" instead of adding it behind them like in the arrangement of the layers.
    So first, can this be done and if so how?
    Second, why is this process so counter intuitive in fireworks? I mean if a layer is behind something then it should be a simple button click or check box etc to say "show on all frames (states)", you know like any other product adobe makes. Even "image ready" made more sense than this.  My thought process was that since I needed to end up in fireworks to create and optimize the gif that i should be able to put it together there also but it's turning out to be a lot harder than it should. I guess I can just composite my elements in AE (which is a piece of cake compared to fireworks) and then render another SEQ that I import to fireworks to create the optimized gif. While I'm a fan of the "creative suite" concept, one of my biggest complaints about the "suite" is the lack of master oversite so the common functions, keyboard shortcuts, and fundimental UI concepts are consitant accross all the apps so it functions as a "suite" and not just a collection of seperate applications. I know that demanding that all applications follow certian rules would slow development, in the long run it would make it a lot easier for the end user to spend more time being "creative" and less time trying to figure out why something doesn't work like it does in all the other apps. Just my $.02
    Thanks for any help and or explaination
    Joel H

    Thanks for the response.
    You know I tried that exact thing the only difference being I didn't change the layer names. So not naming the layers would keep that from working ?? Also as you eluded to draging layers to position them in fireworks is a delicate operation. It always seems to take 2 or 3 times to get it to drop where you want it. I named the layers and it works as you said.  Unfortunately I was really pressed for time so I had already given up on fireworks and just composited the SEQ with the BG layer in AE and kicked out another PNG SEQ and then open that "as animation" in Fireworks and then optimized and exported as a gif. So there are allways several ways to do things.
    Thanks again,
    Joel H

  • Minimize all frames

    i've got a program running, which if one of the window is being minimized all of the opened windows which is opeened will be minimized, and if clicked ffrom the taskbar all will be restored .. here is the code ....
    private void iconifyAllWindows(int state){
         int iterator;
         //Returns an array containing all Frames created by the application.
            Frame[] frame = getFrames();
             for(iterator = 0; iterator < frame.length; iterator++){
                   if(state == 0){
                      frame[iterator].setState(ICONIFIED);
                 }else if(state == 1){
                    frame[iterator].setState(NORMAL);
    }but this code has a prob .. if doing a fast double click in the taskbar to minimize or to maximize .. it will do an endless looping of minimizing the frames and maximizing.
    any ideas ??

    Posting this method is ok, but we can't guess on
    which event / context it will be called...oh ok .. forgot that part .. apologies .. here it is
         public void windowOpened(WindowEvent e) {}
         public void windowClosed(WindowEvent e){}
         public void windowActivated(WindowEvent e) {}
         public void windowDeactivated(WindowEvent e){}
         public void windowClosing(WindowEvent e) {
            System.exit(0);
         public void windowIconified(WindowEvent e) {
            iconifyAllWindows(0);
         public void windowDeiconified(WindowEvent e) {
            iconifyAllWindows(1);
        

  • Copy roto selection to same position in all frames

    I am using AE CS5 in Production Premium. I also have moca AE 3.1 that may be a better way of trying to isolate an object using planar tracking.  I need to replace an item that appears in the same position on all frames of a clip.  This is a previous problem I covered some time ago involving a spiders web that was fixed on an 8mm film gate.  As a result, the web appears on the top left hand corner of every frame in the clip.  Perhaps a different approach will work.  This is complicated because the background behind the item changes such that the boundaries of the selected item become blurred.  I will need to further isolate sections of the clip where there is similar background interference, e.g. a background of mostly dark trees in the top left may to be passable.  There may be a way I can gradually replace the web with background that appears in following frames as the background moves by using duplicate layers.
    How can I roto select the item in the first frame and copy the boundaries of the selection to all frames or is there a better way of doing this?

    How can I roto select the item in the first frame and copy the boundaries of the selection to all frames or is there a better way of doing this?
    You don't. You're thinking in wrong terms here and will work yourself to death if you follow that approach. Instead export a frame, isolate the pattern as a clean greyscale image in Photoshop. Then you can either use it as a matte to punch out the disturbances directly or by creating proper transparency, possibly in a pre-composition by using it as a luma matte on a white solid, as an input for an adjustment layer. Then you can eitehr just fill in the blanks with a copy of your footage that you have slightly shifted in position or in the second case apply effects liek Minimax, Matte Choker and varius blurs to fill the gaps. CC VEctor Blur with the transparency channel as the input will do miracles to "sew" such stuff together. Of course you might also consider RevisionFX' RE:Fill as sort of a canned and pimped plug-in tool set for these kinds of things...
    Mylenium

  • Show all frames in the timeline - CC version

    Show all frames option is not available in the track header anymore. How can I see all the frames inside the clips in the timeline?

    Click the picture of the wrench (or spanner if you're British) on the timeline
    Tick "show video thumbails" from the dropdown menu
    THEN go to the flyout menu on the top right of the timeline and choose "continuous video thumbnails"
    There are lots of great options in that menu for customising your timeline settings.
    Also you can create and save presets for these settings.

  • Can't find the Recompress All Frames option

    Does anyone know how to access/locate the "Recompress All Frames" option mentioned on page 1015 of the Final Cut Express 4 Users Manual?
    To quote the text:
    +"Exporting a Self-Contained Movie Without Recompressing the Media+
    +If you choose to export a self-contained movie, you have the option to not recompress+
    +the media in your clip or sequence. If you deselect the Recompress All Frames option+
    +and choose Current Settings from the Setting pop-up menu, Final Cut Express simply+
    +copies frames from existing media files into the new file with no recompression. This is+
    +a convenient way to export your media without subjecting it to recompression+
    +artifacts. However, any media that must be created from scratch, such as a transition+
    +between two media files, must be recompressed.+
    +Important: The option to turn off recompression is unique to the Export QuickTime+
    +Movie command. If you choose the Export Using QuickTime Conversion command,+
    +every frame is always recompressed. "+
    Whenever I click on a Sequence in the Browser, select FILE, then EXPORT, then QUICKTIME MOVIE the option does not exist, contrary to what is stated in the users manual. I am interested in locating this option as according to the manual, all other efforts to export the Sequence will result in a recompression of the video.

    Just to add to what Michel said, when you export to QuickTime Movie the recompress all frames function is off by default. Because you can only export in current settings when you export to QuickTime Movie there is no real need for a recompress all frames button.

  • Does any one know how to Create MDI data form frame

    Has any one created MDI data form frame in JDev. Please tell me step-by-step procedure to create a MDI data form frame.
    Or any way to remove/add some menu item in BC4J default browser.
    Thanks
    null

    Hi jaya,
    What do you mean by creating URL for a word document?
    You can display all the files in ABAP by giving the location(u mean URL!).
    call function 'CALL_BROWSER'
            exporting
              url = 'http://www.sap.com'.
    or
    call function 'CALL_BROWSER'
            exporting
              url = 'c:/test.doc'.
    Rgds,
    Jothi.P
    *Reward pts if useful.

  • I converted video into frames. There is a big difference between video size(700 MB) and All frames s

    I converted video into frames. There is a big difference between video size(700 MB) and All frames size(More than 5 GB). What are the reasons ?

    Please, are you sure that you posted this in the correct forum? This is the Adobe Captivate forum, not a forum for video created with other applications like Premiere Pro.
    Lilybiri

  • Hello, 2 questionss here is it possible or is there a way to convert all object s outlines in all frames to fills at once and not frame by frame? and why sometimes erases the outline instead of converting it to fill?

    Hello, 2 questionss here>is it possible or is there a way to convert all object s outlines in all frames to fills at once and not frame by frame? and why sometimes erases the outline instead of converting it to fill?

    Hello, 2 questionss here>is it possible or is there a way to convert all object s outlines in all frames to fills at once and not frame by frame? and why sometimes erases the outline instead of converting it to fill?

  • How to print a message in the Window created out of a Frame Object

    Hello,
    I created a class extended from Thread class
    I want to print a message in Run method : in the Window created out of a Frame Object in the main function.
    I used System.out.println function, but nothing is printed on the screen
    what other function can I use, without using Drawstring method in ie public void paint(Graphics g)Thank you

    Erm...I don't know whether this is acceptable or not, but...if you want to create out of the main frame, why dun u you create a new frame with a button there, so it seems like a pop-up windows (***or like JOptionPane.showMessageDialog)
    P.F.Boy

  • Creating sequences for all tables in the database at a time

    Hi ,
    I need to create sequences for all the tables in my database.
    i can create individually ,using toad and sqlplus.
    Can any one give me a code for creating the sequences dynamically at a time for all the tables.
    it is urgent ..
    Regards.

    I need to create sequences for majority of the tables that are having ID column
    which is sequences."The majority" is not the same as all. So you probably want to drive your generation script off the ALL_TAB_COLUMNS view...
    where column_name = 'ID'You need to think about this carefully. You might want different CACHE sizes or different INCREMENT BY clauses for certain tables. You might even (whisper it) want a sequence to be shared by more than one table.
    Code generation is a useful technique, but it is a rare application where one case fits all.
    Cheers, APC
    Blog : http://radiofreetooting.blogspot.com/

  • I want to create a "Play All" chapter marker that will play the video from start to finish in addition to the standard chapters I have-I guess I can auto start the DVD but would prefer a button-how and where would I put this "play all" marker??

    I want to create a "Play All" chapter marker that will play the video from start to finish in addition to the standard chapters I have…I guess I can auto start the DVD but would prefer a button…how and where would I put this "play all" marker?? Thanks..

    The start chapter button is a play the whole movie button regardless of how many other markers you have.
    Once a DVD starts playing it continues to the end.
    Chapters marker simply gives the viewer a place to start playback whether it be the start, middle or near the end.
    Al

  • External Monitor Viewing - ALL FRAMES Unchecked

    Hello FCP gurus
    I cannot get a video signal on my external monitor.
    For some reason I have lost the ability to check the ALL FRAMES option in the View Menu under External Video. Each time I click ALL FRAMES it stays in the OFF mode. I think this may be the reason for the external picture loss? I have also just relocated my edit suite so somewhere in the move I might have upset the 'workflow'. Not sure, can't see why? Before today I was getting an external picture no problem.
    The configuration I have is: A Firewire connection from the Hard Drive to a DV Cam (PD150). RCA Vid connector from the cam into a domestic TV.
    I have followed all of Shane's #8 Stock Answer and still nudda!!
    Can anyone help?
    Thanks in advance!
    josie
    P.S. I work in Pal
    #8 External Monitor Viewing.
    Shane's Stock Answer #8:
    A simple path is mac > firewire > camera or deck > rca cables > tv
    Then start up your camera and tv, then open fcp.
    Then go View > External video > all frames
    Video playback should be Apple firewire NTSC (If you are using an NTSC set)
    Audio playback should be Audio follows Video
    Techinially, this should send synched video to your TV
    If for some reason you can't view your timeline on your external monitor, there are a few things to try:
    1) Make sure that the camera/deck is connected and powered on BEFORE you open FCP.
    2) In the Final Cut Pro menu select AUDIO/VIDEO Preferences and make sure your signal is being sent out thru Firewire DV.
    3) Go to the menu and select VIEW>EXTERNAL>ALL FRAMES.
    4) Click in the % box above the image and select FIT TO WINDOW.
    5) Go to VIEW->refresh A/V devices
    6) Make sure the Log & Capture window is closed
    If you want it to play in both the canvas and the external monitor you need to go to the FINAL CUT PRO menu and select AUDIO/VIDIO settings and make sure MIRROR ON DESKTOP is selected under the PLAYBACK OUTPUT section
    Shane
    G5 Mac OS X (10.4.8) FCP 5.1.2

    Heck, I don't know, but reading your question helped me to finally figure out how to get my external monitor working.
    Would it be okay to add to your question. Now that I have mine working the audio goes through the monitor instead of my nice Cerwin-Veg speakers. Is there a way to fix that?
    P.S. Have you tried a power down, hooking up the monitor and then coming back up?

Maybe you are looking for

  • How to add space before a string a variable.

    Hi, If i have a string variable  ' 80 '.I want it as '    80 ' ie some space appended before it. I used  concatenate '   '    variable into variable..Its not working.How to do it?? Thanks.

  • N0 Collective slip is printing in MB90

    Hi Experts, I maintained configuration settings and condition records for both out put types WE01 and WE03. When  I do the GR Collective slip in the general tab is automatically activated and I can see the both out put types WE01 and WE03 in the out

  • Access HTML hidden field value in JSP

    Hi, I have a JSP and need to access the hidden fields on that HTML page, i.e. in HTML i have a hidden tag <form name="login"> <input type="hidden" name="language" value="en"> </form> in my jsp i want to read the value of hidden field language how can

  • Techtool deluxe on osx lion does not run video ram test

    I ran Techtool Deluxe after having installed OS X Lion. When it gets to the Video Ram test it quits. If I disable this test all is fine. What's wrong with testing video ram on OSX Lion? Thanks. G

  • SAAJ and namespace

    Hi, I am having a problem in running SAAJ client for Axis running on Tomcat. My SAAJ code is as follows; SOAPConnectionFactory soapConnectionFactory = SOAPConnectionFactory.newInstance(); SOAPConnection connection = soapConnectionFactory.createConnec