# Dynamic text w/ in a movieclip

**URL:** <https://forum.kirupa.com/t/dynamic-text-w-in-a-movieclip/310288>\
**Category:** flash\
**Created:** [June 6, 2010, 10:35pm UTC](https://forum.kirupa.com/t/dynamic-text-w-in-a-movieclip/310288 "2010-06-06T22:35:12Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![ballzd33p](https://avatars.discourse-cdn.com/v4/letter/b/a87d85/32.png) [@ballzd33p](https://forum.kirupa.com/u/ballzd33p)\
**Post date:** [June 6, 2010, 10:35pm UTC](https://forum.kirupa.com/t/dynamic-text-w-in-a-movieclip/310288/1 "2010-06-06T22:35:12Z")

</div>

using flash cs4

I’m trying to load dynamic text from within a movie clip…

## my actionscript, from within the movieclip, is:

var content\_req:URLRequest = new URLRequest (“What.txt”);  
var content\_ldr:URLLoader = new URLLoader (content\_req);  
content\_ldr.addEventListener(Event.COMPLETE, onComplete);

function onComplete(event:Event):void  
{  
content\_txt.htmlText=event.target.data;  
}

* * *

im pretty sure i need to edit the “content\_txt.htmlText=event.target.data;” line since im within a movie clip, and not on the main time line, but the several variations ive tried out aren’t working…

also, “What.txt” is the proper name of the text file, and is stored in the same folder as my flash file.  
anyone got some helpz for me?

thanks
