0 Replies Latest reply on May 27, 2010 8:02 AM by R-henry

    Flex 4 wipedown effect...

    R-henry

      Hello  guys,

      I'm having some difficulties with part of the purpose of flex  4, I'm following a tutorial that teaches flex3 create a component at  runtime:

      private function addPanel (): void (


      var myPanel:  Panel = new Panel / / declare a variable with the new panel

      var myEffect: Effect = new WipeDown;

      / / Declaring effect with new wipedown efect


      mypanel.width = 180 / / length
      mypanel.height  = 115, / / height
      mypanel.x = 0 / / x  position where the panel will appear
      mypanel.y = 0, / /  y position where the paindel will appear
      mypanel.id =  "painel3" / / identified as the paindel painel3
      myEffect.target  (myPanel) / / setting the destination / target of the effect wipedown
      this.addElement  (myPanel) / / add as "son" of the "stage" / Display panel
      myEffect.play  ();
      )

       

      TypeError: Error # 1006: value is not a  function.
      at Hello World / addPanel () [C: \ Documents and Settings \  Raphael \ Adobe Flash Builder 4 \ Hello World \ src \ olaMundo.as: 34]
      at  olaMundo/___olaMundo_Button1_click () [C: \ Documents and Settings \  Raphael \ Adobe Flash Builder 4 \ Hello World \ src \ olaMundo.mxml: 9]

       

      Remembering that this code runs perfectly  in flex3.