Marty1963 0 Newbie Poster

I'm trying to reuse an old Flash file that my client wants on his website however I'm using Flash CC now, and the existing code does not funtion in ActionScript3. I can't see why this won't work. Any advise would be greatly appreciated

function randRange(min:Number, max:Number):Number {
    var randomNum:Number = Math.round(Math.random()*(max-min))+min;   
    return randomNum; 
var myFrame; 
myFrame = randRange(2,7); 
Be a part of the DaniWeb community

We're a friendly, industry-focused community of 1.20 million developers, IT pros, digital marketers, and technology enthusiasts learning and sharing knowledge.