Need help with importing variable text

I am trying to generate an SWF that will provide my class with digital notecards. I have a file setup with the format as follows:

w1:English Word&
a1:German Word&

W1 is the word i want to be shown initially, and it is displayed in a dynamic textbox that is overlayed by another one just like it, except for it is for the answer, and i have it so that the visibility of each dynamic textbox changes with which button has been pushed. The problem comes when i have over 30 words, and i don’t want to have to paste this:

word._visible=true
answer._visible=false
loadText = new LoadVars();
loadText.load(“vocab.txt”);
loadText.onLoad = function() {
word.text = this.w1;
page.text= this.page;
answer.text=this.a1
};
stop();

into 30 different frams and change the this.xx; value in each one. Is there any way to have it dynamically progress through the words in the external text file (it is important that the text file is external so that I can easily update and change word lists).

Thanks to all who give this a read, all help is appreciated.