# I get this error message

**URL:** https://forum.kirupa.com/t/i-get-this-error-message/64062
**Category:** flash
**Created:** [September 13, 2004, 12:29am UTC](https://forum.kirupa.com/t/i-get-this-error-message/64062 "2004-09-13T00:29:19Z")
**Posts on this page:** 3
**Page:** 1

<div class="post-metadata">

### Author: ![fabbuki](https://avatars.discourse-cdn.com/v4/letter/f/c89c15/32.png) [@fabbuki](https://forum.kirupa.com/u/fabbuki)
#### Post date: [September 13, 2004, 12:29am UTC](https://forum.kirupa.com/t/i-get-this-error-message/64062/1 "2004-09-13T00:29:19Z")

</div>

OK. I’m trying to make a dynamically scrolling text box. I put in the dynamic text box, set it to multiline. Then, I get my scrollbar component and drag it onto the dynamic text box; it locks in.

OK now it gets weird. I type in the actionscript from the [macromedia.com](http://macromedia.com) tutorial (it’s very similar to the kirupa tutorial script, but even when I use the kirupa script it screws up):

loadVarsText = new loadVars();  
loadVarsText.load(“test.txt”);  
//assign a function which fires when the data is loaded:  
loadVarsText.onLoad = function(success) {  
if (success) {  
trace(“done loading”);  
//Now that we know the data is loaded,  
//set the text content of the Text Field  
//with the instance name “scroller” equal to the  
//contents of the variable  
scroller.text = this.var1;  
} else {  
trace(“not loaded”);  
}  
};

This is supposed to have the text box display the text in text.txt, and I assigned the contents of the variable “var1” (the first line in the txt file is “var1=”)

Then I publish it, and I get THIS problem:

**Warning** Scene=Scene 1, layer=text, frame=1:Line 1: The identifier ‘loadVars’ will not resolve to built-in object ‘LoadVars’ at runtime.  
loadVarsText = new loadVars();  
Total ActionScript Errors: 1 Reported Errors: 1

The published swf is in the same folder as test.txt! The macromedia tutorial source file has the exact code and stuff, AND IT WORKS when published! I don’t know what’s going on. Someone help.

-fabbuki

---

<div class="post-metadata">

### Author: ![system](https://canada1.discourse-cdn.com/flex011/uploads/kirupa/original/3X/6/2/621e5c11736f46532526e61be85940af4230f3e5.png) [@system](https://forum.kirupa.com/u/system)
#### Post date: [September 13, 2004, 7:17am UTC](https://forum.kirupa.com/t/i-get-this-error-message/64062/2 "2004-09-13T07:17:51Z")

</div>

Read the error message;)  
loadVarsText = new **L** oadVars();

scotty(-:

---

<div class="post-metadata">

### Author: ![system](https://canada1.discourse-cdn.com/flex011/uploads/kirupa/original/3X/6/2/621e5c11736f46532526e61be85940af4230f3e5.png) [@system](https://forum.kirupa.com/u/system)
#### Post date: [September 13, 2004, 8:32am UTC](https://forum.kirupa.com/t/i-get-this-error-message/64062/3 "2004-09-13T08:32:47Z")

</div>

You have mis-spelled “LoadVars()” which is starts wit a capital letter.  
[http://www.actionscript.org/forums/showthread.php3?t=43299&goto=nextnewest](http://www.actionscript.org/forums/showthread.php3?t=43299&goto=nextnewest)
