I am having trouble trying to get on object to listen for and react to the user hitting the ENTER key. There is an input text box in frame one of the main timeline. I would like to have this text compared to a variable that I have created when the user hits ENTER. I have pretty much gotten the comparing part down, thanks to rgStewart, it the hitting ENTER part that i can't get down. I know that the comparing code isn't in here, but I have been just trying to narrow down the problem, by working with the least amount of code as possible. Am I on the right track? I have tried
_root.onKeyDown = function (){
x = Key.getAcii();
if (x = 13){
_root.myMovie.gotoAndPlay(5);
}
else {
_root.myMovie.gotoAndPlay(10);
}
}
I am VERY new at this, so I could be completely wrong. I have tried to look at different tutorials and what not, but just can't seem to get it right.
Also, while on the subject. What exactly is the Key.ENTER constant used for?
Thanks in advance...... Erik Rudnick, CCIE No. 9545
mailto:erik@kuriosity.com
_root.onKeyDown = function (){
x = Key.getAcii();
if (x = 13){
_root.myMovie.gotoAndPlay(5);
}
else {
_root.myMovie.gotoAndPlay(10);
}
}
I am VERY new at this, so I could be completely wrong. I have tried to look at different tutorials and what not, but just can't seem to get it right.
Also, while on the subject. What exactly is the Key.ENTER constant used for?
Thanks in advance...... Erik Rudnick, CCIE No. 9545
mailto:erik@kuriosity.com