# Dynamic text won't load into runtime TextField

**URL:** <https://forum.kirupa.com/t/dynamic-text-wont-load-into-runtime-textfield/136703>\
**Category:** Uncategorized\
**Created:** [February 7, 2005, 10:22pm UTC](https://forum.kirupa.com/t/dynamic-text-wont-load-into-runtime-textfield/136703 "2005-02-07T22:22:35Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![prototype](https://avatars.discourse-cdn.com/v4/letter/p/e19adc/32.png) [@prototype](https://forum.kirupa.com/u/prototype)\
**Post date:** [February 7, 2005, 10:22pm UTC](https://forum.kirupa.com/t/dynamic-text-wont-load-into-runtime-textfield/136703/1 "2005-02-07T22:22:35Z")

</div>

I can’t get my text to show in a text field created at runtime within a movieclip on \_root. I use a trace statement and it loads into the Output box but is not visible in the textField area. Thanks for help or ideas. btw…_there are no masks in the movieClip._

My function for creating it…

// Call the function to create textField  
printBtn.onRelease = function() {  
makeTxtBox(“text/print.txt”);  
}

// Create the textField  
function makeTxtBox(txtFile) {  
var txtFile;  
this.createTextField(“txtBox”,0,87,-58,358.4,198);  
txtBox.multiline = true;  
txtBox.wordWrap = true;  
txtBox.border = false;  
txtBox.embedFonts = true;  
this.loadVariables(txtFile);  
txtBox.variable = infoText;  
txtBox.text = infoText;  
trace(txtFile + “\<-- **LOADED** --\>” + infoText);  
defaultFormat = new TextFormat();  
defaultFormat.font = “Futura MdCn BT”;  
txtBox.defaultFormat.size = 16;  
txtBox.defaultFormat.color = 0x666666;  
txtBox.setTextFormat(defaultFormat);

}
