# autoSize Help

**URL:** <https://forum.kirupa.com/t/autosize-help/316161>\
**Category:** flash\
**Created:** [November 14, 2010, 9:09pm UTC](https://forum.kirupa.com/t/autosize-help/316161 "2010-11-14T21:09:28Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![treeleaf20](https://avatars.discourse-cdn.com/v4/letter/t/bb73d2/32.png) [@treeleaf20](https://forum.kirupa.com/u/treeleaf20)\
**Post date:** [November 14, 2010, 9:09pm UTC](https://forum.kirupa.com/t/autosize-help/316161/1 "2010-11-14T21:09:28Z")

</div>

All,  
I have the following code to populate a dynamic text box:

```auto

myData = new LoadVars();
myData.onLoad = function() {
trace ("The text box before autosize is: " + sailing_txt._height);
sailing_txt.htmlText = unescape(this.myVariable);
sailing_txt.autoSize = true;
trace ("The text box after autosize is: " + sailing_txt._height);
}; 
myData.load("sailing.txt");

```

The output of this is:  
The text box before autosize is: 388.25  
The text box after autosize is: 712.5

My problem is that I need to get the autosized height instead of the regular height of the text box before autosize. In a parent movie clip I have the following code to do some custom scrolling:

```auto

contentHeight = _parent.scrolledMC.sailing_txt._height;
trace("The content height is: " + contentHeight);

```

The output of this is:  
The content height is: 388.25

So it’s getting the size of the text box before it’s autosized. How can I fix this?

Thanks in advance!
