Typewritter effect on dynamic text field

[FLASH MX]

I am trying to get a ’ Typewritter effect ’ on a dynamic text field that imports txt from external txt file. Trying to decipher some code I found in an example that created typewritter effect but text was declared in strings and not reading from external txt file. So I am trying to adapt it some. The effect works but when it runs it only displays my text field instance name and not the actual text from the txt file. I have attached the file if anyone could give me any suggestions I would appreciate it.

Thanks!

[AS]var loadText = new loadVars();
loadText.load(“text.txt”);
loadText.onLoad = function(OK) {
if (OK) {
content = this.news;
} else {
mytext.text = “Error”;
}
};
this.onEnterFrame = function() {
mytext.text = content.substr(0, type);
type += 1;
};

Thanks claudio. Worked great and you achieved the same effect using about half the code! :slight_smile:

Welcome =)