2 Replies Latest reply on Jun 26, 2007 12:48 PM by SymTsb

    Duplicate MC Problem

    BarryGee Level 1

      I am loading data into the flash file from an xml file. The xml file defines the path for images to be loaded from an external folder. The flash file counts the number of nodes in the xml file and duplicates the MovieClip "imageLoader" for each node and places an image into each new MC. My problem is this. The MC is duplicating or at least seems to be doing as all of the images are loading into the flash file and the trace command (see code) is outputting the names of the new MCs as they are created. If i then draw a shape or add a text box into the initial "imageLoader" MC these elements do not duplicate when the imageLoader MC does, these elements only appear in the first MC and only the images that are defined by the XML file appear in the rest.

      All help / advice very welcome.



        • 1. Re: Duplicate MC Problem
          MurMeeKeer Level 1
          Hi Barry,

          How are you?
          This is working fine for me. Or, I might have understood your problem wrongly. If you send your mail id, I'll send my work.
          • 2. Re: Duplicate MC Problem
            SymTsb Level 2
            That's because the imageLoader is going to overwrite the contents of the duplicate mc. you are using loadMovie on the clip when you load the images. loadMovie will overwrite the contents of the target movie clip no matter what. If you want to have the shapes and other objects stay you need to take a different approach....

            dynamically draw the contents inside the mc you are going to duplicate above level 1
            duplicate that mc
            create an empty movieclip inside the duplicate that wil hold the images at level 1
            load the image into the empty movie clip...