6 Replies Latest reply on Oct 9, 2013 9:29 AM by Amy Blankenship

    ActionScript 3 Error: 1046: Type was not found or....

    Mandy Root-Thompson

      Hi,

       

      I am completely new to Flas and AS3. I am trying to create an opacity slider using the slider component. I foudn a similar tutorial and tried to alter it to fit my opacity needs. In line 8 (function opacityChange (event:SliderEvent):void{) I get the error message 1046. When I test it in Flash the slider flickers on and off very rapidly too. Though I have searched, I am clueless as to what the problem is.

       

      Any help will be appreciated.

       

      Thanks!!

       

      importfl.events.SliderEvent;

       

      percent_txt.text = "Opacity %:0";

      slider.value = 0;

       

       

      slider.addEventListener(SliderEvent.CHANGE,opacityChange);

       

       

      function opacityChange (event:SliderEvent):void{

                percent_txt.text = "Opacity %: " + event.target.value;

                logo.alpha = event.target.value;

      }