Is it possible to have multiple cases in a switch statement
Hi,
I made a carousel, which required that I added 44 items in order to get the 15 clips showing on the front plane..However, I only have 10 items which are repeated...
I have a function that uses a switch statement based on the number assigned to the clip---now being that I have only 10 items the different clips in the carousel are arranged like this:
0 is the same as 10 is the same as 20 is the same as 30 is the same as 40.
So, I was wondering if you could do something like this:
Code:
switch (arrcontentNum)
{
case 0 || 10 || 20 || 30 || 40:
//myContent.fade.visible = true;
myLoadURL = "yahoomessengervistaresizedas3.swf";
swfX = -275;
swfY = -183;
swfZ = swfZholder = 100;
break;
That doesn't work, do I have to write out all 44 possible case numbers even if there are only 10 clips?
Thanks,
---Yvette