I have text loading into a text box via the following code:
loadText = new LoadVars();
loadText.load("main.txt");
loadText.onLoad = function() {
scroller.text = this.textsrc;
};
This works beautifully and I am happy with it. However, I would like to ActionScript (2.0) to change where the text loads from on the release of a button I have made. I tried putting this on the button, but it did not work:
on (release) {
loadText.load("about.txt");
loadText.onLoad = function() {
scroller.text = this.textsrc;
};
I’m hoping this is an easy thing to do and I am just too new or tired to see it. Anyway, any help would be appreciated. Thanks!