Question about random function

Hello,

I have three different texts I would like to have inside an MC -txt1, txt2, + txt3. I would like one of these three texts to appear when the MC they are in is reached on the main timeline. I want them to be randomly selected to appear on frame one of the MC. I thought if I used dynamic text inside the MC I could have an actionScript randomly call one of the three texts to appear in the dynamic text window, but I’m having trouble with the script. Here’s what I’ve got so far, I don’t understand it entirely and it isn’t functioning, but it’s a start:

txt1 = “first text appears here”;
txt2 = “second text appears here”;
txt3 = “third text appears here”;

var i:Number = Math.ceil(Math.random()*3);
mc.mc_text = eval(“txt”+i);

Any help would be appreciated. Thanks,

Llyfre