# Getting variables from external text file

**URL:** <https://forum.kirupa.com/t/getting-variables-from-external-text-file/149583>\
**Category:** Uncategorized\
**Created:** [May 30, 2005, 9:39pm UTC](https://forum.kirupa.com/t/getting-variables-from-external-text-file/149583 "2005-05-30T21:39:43Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![jawasdi](https://avatars.discourse-cdn.com/v4/letter/j/9f8e36/32.png) [@jawasdi](https://forum.kirupa.com/u/jawasdi)\
**Post date:** [May 30, 2005, 9:39pm UTC](https://forum.kirupa.com/t/getting-variables-from-external-text-file/149583/1 "2005-05-30T21:39:43Z")

</div>

I have been trying to get more than one variable read into flash from a .txt file.

this is my code, in first frame:  
[INDENT]loadText = new LoadVars();\<br\>loadText.load(“testing.txt”);\<br\>loadText.onLoad = function() {\<br\>\_root.loadText.loadVariables();\<br\>trace(var1);\<br\>trace(var2);\<br\>};[/INDENT]

and this is the text file “testing.txt”:  
[INDENT]var1=kjkdjf&var2=“76”[/INDENT]

basically i just want to be able to import a whole bunch of variables from a file…
