PLEASE HELP me :(

PLEASE HELP PLEASE HELP IM A NOOOOOOOB

Hello, I’m very new to FLASH. I just started learning it, a few weeks ago, and I’m trying to write a FLASH advertisement, that will switch between 4 movie clips every 7 seconds (advertisement0, advertisement1, advertisement2, advertisement 3). And the way it switches, it takes the current movie clip and fades it out, then the new movie clip fades in.

THIS IS MY FIRST FLASH PROJECT, so If the code is completely noob, then I’m sorry, but any help would be greatly appreciated. Thanks to anyone who can help.

okay, here is my problem, I cant figure out how to write or structure my code to do this effectively. I dont know how to change the alpha of the current movie, and change the alpha of the next movie, this is what I have and it is not working.


//stop(); 
var myMCL:MovieClipLoader = new MovieClipLoader(); 
var movieClipNumber:Number = 0; 
//keeps track of which movieClip we're on 
myMCL.loadClip("advertisement"+movieClipNumber, container); 
 
//execute function nextMovieClip every 7 seconds and never stop 
timeInterval = setInterval(nextMovieClip, 7000, movieClipNumber); 
 
//<<<<<<<<<<<<nextMovieClip>>>>>>>>>>>> 
function nextMovieClip(mcNumber) { 
   if (mcNumber == 3) { 
      _root.movieClipNumber = 0; 
      fadeOut; 
      fadeIn; 
   } else { 
      _root.movieClipNumber = mcNumber++; 
      fadeOut; 
      fadeIn; 
   } 
} 
//<<<<<<<<<<<</nextMovieClip>>>>>>>>>>>> 
 
//<<<<<<<<<<<<fadeOut>>>>>>>>>>>> 
function fadeOut() { 
   var currentMcNumber:Number = _root.movieClipNumber; 
   //if the current movieClipNumber is 0, then the last movie was 3 
   //else, the last movie clip is movieClipNumber minus 1 
   if (currentMcNumber == 0) { 
      currentMcNumber = 3; 
   } else { 
      currentMcNumber--; 
   } 
 
        // variable idontKnow points to the current movieClip? really, idk. 
   var idontKnow:String = "_root.advertisement"+currentMcNumber; 
   var fadeOutNumber = 0; 
 
   function fadeOutProcess() { 
      if (fadeOutNumber>=19) { 
         clearInterval(fadeoutInterval); 
      } else { 
         idontKnow._alpha -= 5; 
         fadeOutNumber++; 
      } 
   } 
   /*every 3 milliseconds run fadeOutProcess, until fadeOutProcess 
   runs 20 times, which is equivalent to 0.6 seconds. So, every 3 milliseconds 
   the current MovieClip's alpha will be reduced by 5, twenty times.*/ 
 
   fadeoutInterval = setInterval(fadeOutProcess, 3); 
} 
//<<<<<<<<<<<</fadeOut>>>>>>>>>>> 
 
//<<<<<<<<<<<<fadeIn>>>>>>>>>>>> 
/*same as fadeOut, every 3 milliseconds, increase alpha by 5 */ 
function fadeIn() { 
   var fadeInNumber = 0; 
   var idontKnow:String = "_root.advertisement"+_root.movieClipNumber; 
   myMCL.loadClip("advertisement"+movieClipNumber, container); 
   idontKnow._alpha = 0; 
 
   function fadeInProcess() { 
      if (fadeInNumber>=19) { 
         clearInterval(fadeInInterval); 
      } else { 
         idontKnow._alpha += 5; 
         fadeInNumber++; 
      } 
   } 
 
   fadeInInterval = setInterval(fadeInProcess, 3); 
} 
//<<<<<<<<<<<</fadeIn>>>>>>>>>>>> 

I’m completely stumped on this one, I dont know where to go

When I try and run the program it says idontKnow._alpha is invalid

I know I’m not referencing the current movie clip correctly, but I dont know of any methods to reference it. Someone please help me.