9 Replies Latest reply on Aug 12, 2011 6:37 AM by kglad

    moviclip content

    narmathadevi Level 1

      Hi,

       

           In my application using the window component and dynamically create the movieclip .how to assign this movieclip to window component.

        • 1. Re: moviclip content
          kglad Adobe Community Professional & MVP

          assign your movieclip's linkage id to the contentPath property of you window instance:

           

          yourwindow.contentPath="mcID";

          • 2. Re: moviclip content
            narmathadevi Level 1

            i am creating the dynamic movieclip  -"mc" - this movieclip how to assign the window component.

             

            For example:

             

                 my_win = PopUpManager.createPopUp(this, Window, true, {closeButton:true, title:"Sample"});

                 mc=_root.createEmptyMovieClip("mc1",_root.getNextHighestDepth());
                 mc.beginFill(0xff0000,100);
                 mc.moveTo(0,0);
                 mc.lineTo(50,0);
                 mc.lineTo(50,50);
                 mc.lineTo(0,50);
                 mc.lineTo(0,0);

            • 3. Re: moviclip content
              kglad Adobe Community Professional & MVP

              create a movieclip with nothing on its stage and assign a linkage id.  assign your window's contentPath and the apply your draw methods to the content property of your window.

              1 person found this helpful
              • 4. Re: moviclip content
                narmathadevi Level 1

                i am assigning the moviclip name to window component contentpath but "  Error opening URL 'file:///C|/xampp/htdocs/popupmanager/mc'   " this error displayed.

                 

                 

                ex:

                 

                    my_win = PopUpManager.createPopUp(this, Window, true, {closeButton:true, title:"Sample"});
                    mc=_root.createEmptyMovieClip("mc1",_root.getNextHighestDepth());
                    mc.beginFill(0xff0000,100);
                    mc.moveTo(0,0);
                    mc.lineTo(50,0);
                    mc.lineTo(50,50);
                    mc.lineTo(0,50);
                    mc.lineTo(0,0);
                    mc._visible=false;
                    my_win.contentPath="mc";
                    my_win.redraw(true)

                 

                 

                error:

                 

                       Error opening URL 'file:///C|/xampp/htdocs/popupmanager/mc'   "

                 

                where,

                popupmanager -folder name

                mc-that moviclip

                • 5. Re: moviclip content
                  kglad Adobe Community Professional & MVP

                  again:

                   

                  create a movieclip with nothing on its stage and assign a linkage id.   assign your window's contentPath and the apply your draw methods to the  content property of your window.

                  1 person found this helpful
                  • 6. Re: moviclip content
                    narmathadevi Level 1

                    i want create the movieclip in runtime.

                     

                    my_win = PopUpManager.createPopUp(this, Window, true, {title:"Sample",closeButton:true});
                    mc=my_win.createEmptyMovieClip("mc1",my_win.getNextHighestDepth());

                     

                    Is it correct?

                    • 7. Re: moviclip content
                      kglad Adobe Community Professional & MVP

                      you can create your movieclip during runtime but not the way you're doing it IF you want the newly created movieclip to be displayed in the window component.

                       

                      your two lines of code are correct if you're importing the needed classes.

                      1 person found this helpful
                      • 8. Re: moviclip content
                        narmathadevi Level 1

                        Thanks ..............

                        • 9. Re: moviclip content
                          kglad Adobe Community Professional & MVP

                          you're welcome.