# Need Your Help! Loading Multiple External Text into Multiple Dynamic Text Fields

**URL:** <https://forum.kirupa.com/t/need-your-help-loading-multiple-external-text-into-multiple-dynamic-text-fields/183862>\
**Category:** Uncategorized\
**Created:** [March 30, 2006, 7:12pm UTC](https://forum.kirupa.com/t/need-your-help-loading-multiple-external-text-into-multiple-dynamic-text-fields/183862 "2006-03-30T19:12:21Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![Flash\_Boi](https://avatars.discourse-cdn.com/v4/letter/f/b5ac83/32.png) [@Flash\_Boi](https://forum.kirupa.com/u/Flash_Boi)\
**Post date:** [March 30, 2006, 7:12pm UTC](https://forum.kirupa.com/t/need-your-help-loading-multiple-external-text-into-multiple-dynamic-text-fields/183862/1 "2006-03-30T19:12:21Z")

</div>

Hi all,

I can’t seem to get the external tex file loaded into a dynamic text field.  
I am trying to display an external text file into a dynamic text field using a next page button. The layout is this I have 80 frames. Frames 1-10 with a static text field with text & a next page button and Frames 11-20 with a dynamic text field with a previous button. I want to onRelease of the next page button in the first set of 10 frames to load the external text file into the dynamic text field of the next set of 10 frames. Also, being able to jump back and forth from next page to next.

Below I layed out all the contents in my test.fla file.

Hope this will give you an understanding of what I am trying to do.

I need to be able to click a next page button and loading an external text file into a dynamic text field, vice versa.

I have set the variable in the text file.

I used this code to try and load the text file into a dynamic text field, using actinscript. Which frame or frames do I need to include this script in? I know it has got to be multiple ones.

var styles = new TextField.StyleSheet();  
styles.load(“cssdocName.css”);

textfieldName.html = true;  
textfieldName.styleSheet = styles;

var lv:LoadVars = new LoadVars();

lv.onData = function(content) {  
textfieldName.text = content;  
}

lv.load(“htmldocName.html”);

Thanks for your time!

I have 6 different layers with 80 frames:

Layer titles:

- labels
- actions
- next\_prev buttons
- contents
- tabs
- outline

Now in each layer:

- outline layer: just an outline border [displayed in Frames 1-80]

- tabs layer: movie clips tab1, tab2, tab3 within each tab is a movie clip  
called bottomline [displayed in Frames 1-80]

- contents layer: Static Text Field [displaying text in Frames 1-10]  
Frame 1 ActionScript  
stop();

Dynamic Text Field instance name dpmoreinfo\_txt  
[displayed in Frames 11-20]  
Frame 11 ActionScript  
stop();

Dynamic Text Field instance name dpmoreinfo2\_txt  
[displayed in Frames 21-30]  
Frame 21 ActionScript  
stop();

Static Text Field [displaying text in Frames 31-40]  
Frame 31 ActionScript  
stop();

Dynamic Text Field instance name spmoreinfo\_txt  
[displayed in Frames 41-50]  
Frame 41 ActionScript  
stop();

Static Text Field [displayed text in Frames 51-60]  
Frame 51 ActionScript  
stop();

Dynamic Text Field instance name cmoreinfo\_txt  
[displayed in Frames 61-70]  
Frame 61 ActionScript  
stop();

Dynamic Text Field instance name cmoreinfo2\_txt  
[displayed in Frames 71-80]  
Frame 71 ActionScript  
stop();

next\_prev buttons  
layers: dpmoreinfonext\_btn [Frames 1-10]  
Frame 1 ActionScript  
dpmoreinfonext\_btn.onRelease = function() {  
gotoAndStop(“dpmoreinfo”);  
};

dpprev\_btn & dpmoreinfo2next\_btn [Frames 11-20]  
Frame 11 ActionScript  
dpprev\_btn.onRelease = function () {  
gotoAndStop(“DataPulse”);  
};

dpmoreinfo2next\_btn.onRelease = function () {  
gotoAndStop(“dpmoreinfo2”);  
};

dpmoreinfoprev\_btn [Frames 21-30]  
Frame 21 ActionScript  
dpmoreinfoprev\_btn.onRelease = function () {  
gotoAndStop(“dpmoreinfo”);  
};

spmoreinfonext\_btn [Frames 31-40]  
Frame 31 ActionScript  
spmoreinfonext\_btn.onRelease = function () {  
gotoAndStop(“spmoreinfo”);  
};

spprev\_btn [Frames 41-50]  
Frame 41 ActionScript  
spprev\_btn.onRelease = function () {  
gotoAndStop(“StructurePulse”);  
};

cmoreinfonext\_btn [Frames 51-60]  
Frame 51 ActionScript  
cmoreinfonext\_btn.onRelease = function () {  
gotoAndStop(“cmoreinfo”);  
};

cprev\_btn & cmoreinfo2next\_btn [Frames 61-70]  
Frame 61 ActionScript  
cprev\_btn.onRelease = function () {  
gotoAndStop(“Courses”);  
};

cmoreinfo2next\_btn.onRelease = function () {  
gotoAndStop(“cmoreinfo2”);  
};

cmoreinfoprev\_btn [Frames 71-80]  
Frame 71 ActionScript  
cmoreinfoprev\_btn.onRelease = function () {  
gotoAndStop(“cmoreinfo”);  
};

labels layer: Frame name is DataPulse [Frame 1-10]  
Frame name is dpmoreinfo [Frame 11-20]  
Frame name is dpmoreinfo2 [Frame 21-30]  
Frame name is StructurePulse [Frame 31-40]  
Frame name is spmoreinfo [Frame 41-50]  
Frame name is Courses [Frame 51-60]  
Frame name is cmoreinfo [Frame 61-70]  
Frame name is cmoreinfo2 [Frame 71-80]

Actions layer: Frame 1 ActionScript

contents.stop();  
numberOfTabs = 3;  
for (i=1; i\<=numberOfTabs; i++) {  
line = eval(“tab”+i);  
line.onRelease = function() {  
for (i=1; i\<=numberofTabs; i++) {  
otherTabs =  
eval(“this.\_parent.tab”+i);  
otherTabs.bottomLine.\_visible =  
true;  
}  
this.bottomLine.\_visible = false;  
contentFrame = Number (this.\_name.substr(3,  
1));  
this.\_parent.contents.gotoAndStop(contentFrame);  
}  
}  
tab1.bottomLine.\_visible = false;

tab1.onPress = function() {  
gotoAndStop(“DataPulse”);  
};

tab2.onPress = function() {  
gotoAndStop(“StructurePulse”);  
};

tab3.onPress = function() {  
gotoAndStop(“Courses”);  
};

---

<div class="post-metadata">

**Author:** ![Flash\_Boi](https://avatars.discourse-cdn.com/v4/letter/f/b5ac83/32.png) [@Flash\_Boi](https://forum.kirupa.com/u/Flash_Boi)\
**Post date:** [March 30, 2006, 9:29pm UTC](https://forum.kirupa.com/t/need-your-help-loading-multiple-external-text-into-multiple-dynamic-text-fields/183862/2 "2006-03-30T21:29:22Z")

</div>

I Figured it Out! Thanks Anyways!
