# Reading text file

**URL:** https://forum.kirupa.com/t/reading-text-file/252137
**Category:** Uncategorized
**Created:** [February 16, 2008, 4:09pm UTC](https://forum.kirupa.com/t/reading-text-file/252137 "2008-02-16T16:09:53Z")
**Posts on this page:** 1
**Page:** 1

<div class="post-metadata">

### Author: ![bluemagica](https://avatars.discourse-cdn.com/v4/letter/b/a4c791/32.png) [@bluemagica](https://forum.kirupa.com/u/bluemagica)
#### Post date: [February 16, 2008, 4:09pm UTC](https://forum.kirupa.com/t/reading-text-file/252137/1 "2008-02-16T16:09:53Z")

</div>

Please see whats wrong with this code:

```auto

onLoad=function()
{
my_text=new LoadVars()
my_text.load("C:\\Documents and Settings\\Wrkspace\\Desktop\\flash_wordlist.txt");
my_wordlist="";
}
my_text.onLoad=function(success)
{
    if(success)
    {
        my_wordlist=(this.var_wordlist).split(" ");
        trace(my_wordlist)
    }
}

```

the trace dosent showup at all…by the way, this is in the first frame of the timeline, and i am trying to load a wordlist and then use the words in my program separately.  
Is it because flash loads the text file slowly? and what is the solution to what i am trying to do?

PS: I am using flas8, as2
