Gotoand play random frame


In my flash piece I’ve created the follow code in the first frame of the action script layer:

function getRandomLabel():String {
  var labels:Array = new Array("2", "4", "3");
  var index:Number = Math.floor(Math.random() * labels.length);
  return labels[index];

This code is not working properly. It loads frames outside of the array.

My frame labels consist of the frame names 2 3 4