# Action Script Problem

**URL:** <https://forum.kirupa.com/t/action-script-problem/42406>\
**Category:** flash\
**Created:** [February 8, 2004, 10:58pm UTC](https://forum.kirupa.com/t/action-script-problem/42406 "2004-02-08T22:58:35Z")\
**Posts on this page:** 6\
**Page:** 1

<div class="post-metadata">

**Author:** ![jw06](https://avatars.discourse-cdn.com/v4/letter/j/838e76/32.png) [@jw06](https://forum.kirupa.com/u/jw06)\
**Post date:** [February 8, 2004, 10:58pm UTC](https://forum.kirupa.com/t/action-script-problem/42406/1 "2004-02-08T22:58:35Z")

</div>

Ok ive done evertyhing right so far with making text go to a text box. When i test it with ctrl+enter it works fine… it reads the .txt’s fine. when i upload it they wont load the text to the dynamic box… heres my code:

on (release) {  
loadText = new loadVars();  
loadText.load(“news.txt”);  
loadText.onLoad = function(success) {  
if (success) {  
// trace(success);  
newsBox.html = true;  
newsBox.htmlText = this.myNews;  
scroller.text = this.mynews;  
}  
};  
}

And

on (release) {  
loadText = new loadVars();  
loadText.load(“contact.txt”);  
loadText.onLoad = function(success) {  
if (success) {  
// trace(success);  
newsBox.html = true;  
newsBox.htmlText = this.myNews;  
scroller.text = this.mynews;  
}  
};  
}

---

<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:** [February 8, 2004, 11:28pm UTC](https://forum.kirupa.com/t/action-script-problem/42406/2 "2004-02-08T23:28:56Z")

</div>

the coding looks ok, maybe your host doesnt allow loading variables (very unlikely), maybe, i dunno

---

<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:** [February 8, 2004, 11:35pm UTC](https://forum.kirupa.com/t/action-script-problem/42406/3 "2004-02-08T23:35:57Z")

</div>

I would agree with flash4food. Check your server, although unlikely it is possible. You may even have to set the directory so that you are able to read/write to it.

---

<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:** [February 9, 2004, 12:02am UTC](https://forum.kirupa.com/t/action-script-problem/42406/4 "2004-02-09T00:02:57Z")

</div>

the index.htm and swf files all go in to the www/ directory… should i change the code to www/contact.txt and www/news.txt?

---

<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:** [February 9, 2004, 9:31am UTC](https://forum.kirupa.com/t/action-script-problem/42406/5 "2004-02-09T09:31:36Z")

</div>

not if the txt-files also are in the www directory.  
if they are in the root directory (which holds the www folder) and the flashmovie is in the www directory, the code should be “…/contact.txt” without the quotation marks…

---

<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:** [February 9, 2004, 10:31pm UTC](https://forum.kirupa.com/t/action-script-problem/42406/6 "2004-02-09T22:31:57Z")

</div>

:S;S:S:S still not working…
