0 Replies Latest reply on Oct 7, 2006 6:36 AM by Newsgroup_User

    Reload FLV after deletePopUp()

    Level 7
      I have a button that creates and opens a popup window and loads a SWF file
      that contains an FLV inside the media component(Flash MX 2004). I've got the
      code in the main movie to close the popup window (deletePopUp) when the user
      clicks the close button on the popup window.

      That all works fine. But after clicking and closing the popup window,
      clicking the original button won't replay my FLV. It will open the popup
      window. In fact it appears to even be loading the SWF file ... because I've
      got my media component skin displaying. But I don't see the movie.

      So my question is ... if I have a deletePopUp() on the click event of the
      popup window ... how does this affect the movie it is loading? Is there
      something I have to do inside that movie to get this to reload properly the
      second time around?

      Code attached to button in main movie:

      on (release) {
      myWindow = mx.managers.PopUpManager.createPopUp(_root,
      mx.containers.Window, true, {title:"Click on the X on this header to return
      to the main screen.", contentPath:"testing2.swf"});
      myWindow.setSize(720, 520);
      myWindow.closeButton = true;
      myWindow.setStyle("fontSize", 12);
      myWindow.setStyle("backgroundColor", "0xEFEBEF");
      myWindow.move(10, 60);
      //var twListener:Object = new Object();
      twListener.click = function(evt:Object) {
      myWindow.addEventListener("click", twListener);

      Code attached to first frame in the loaded swf file (testing2.swf):

      display._visible = true;
      display.autoPlay = true;
      display.activePlayControl = true;
      display.controllerPolicy = "on";
      display.totalTime = 60;

      I would appreciate any help with this. Thanks.