Start on random frame

Can anyone please help me with getting the correct code in AS3 for starting a swf-file on a random frame? In my file, it should randomly start on frame 2 or 3.

I found a code for AS2, which is

 
function randRange(min, max){   
var randomNum= Math.round(Math.random()*(max-min))+min;   
return randomNum; } 
{     
var say; say = randRange(2,3); gotoAndStop(say); 
}

It works in IE, but not in Firefox and Netscape by some reason.
And anyway, I need it in AS3.

Please help!