title: AS3 document class trouble
body: <p>I just started using the document class in flash cs6 today...</p>
  
  <p>so I learned how to put things on the stage and remove it...but if I make a chain of it it doesn't really work and gives me an error here this is what I mean...</p>
  
  <pre><code>    public var playbtn:SimpleButton;
      public var loadbtn:SimpleButton;
      public var backbtn:SimpleButton;
  
          public function SkoolBook() {
  
              playbtn = new play_button;
              addChild(playbtn);
              playbtn.x=200;
              playbtn.y=200;
  
              playbtn.addEventListener(MouseEvent.CLICK, playbutton);
  
              function playbutton (MouseEvent) {
                  removeChild (playbtn);
                  loadbtn = new load1;
                  addChild(loadbtn);
                  loadbtn.x=500;
                  loadbtn.y=500;
  
  
              loadbtn.addEventListener(MouseEvent.CLICK, loadbutton);
                    function loadbutton (MouseEvent) {
                  removeChild (loadbtn);
                  backbtn = new back_button;
                  addChild(backbtn);
                  backbtn.x=500;
                  backbtn.y=500;
          }
  
              }
  </code></pre>
  
  <hr>
  
  <p>so umm yah I just want a ssimple event that if I click on the play button that button disappears and the load button comes up..and if I click on the load button then my first stage comes up......</p>
  
  <p>is there something here I am misunderstanding... why is this giving me an error?</p>
  
  <p>can somebody please exaplin how to exactly carry out sequences in document class....</p>