# Accessing DynamicText from external class

**URL:** <https://forum.kirupa.com/t/accessing-dynamictext-from-external-class/245355>\
**Category:** flash\
**Created:** [November 28, 2007, 8:32pm UTC](https://forum.kirupa.com/t/accessing-dynamictext-from-external-class/245355 "2007-11-28T20:32:48Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![corvenus](https://avatars.discourse-cdn.com/v4/letter/c/3ab097/32.png) [@corvenus](https://forum.kirupa.com/u/corvenus)\
**Post date:** [November 28, 2007, 8:32pm UTC](https://forum.kirupa.com/t/accessing-dynamictext-from-external-class/245355/1 "2007-11-28T20:32:48Z")

</div>

Hi everyone,

I know this has been asked countless times, I had a look at a many posts concerning this subject, but it got me confused more than anything. For example, I have looked at Senocular’s [Tip of the day](http://www.kirupa.com/forum/showthread.php?p=1952513#post1952513), but i’m still not quite sure what code needs to go where.

Here’s my setup: I have a DynamicText object on the main timeline, which is instantiated as “txtContent”. Now, from an external class (let’s call it LanguageManager, stored in LanguageManager.as) i’m trying to get access to this object so i can pass some text (ex: txtContent.text = “some text”).

So, which code should i put in a separate class file, and which code do i need to put in the class LanguageManager? Also, do i need to do :

```auto
addChild(txtContent);

```

in the main timeline even if the object is already sitting on the stage?

Thanks in advance for any help!
