# Play tween after the content is loaded

**URL:** <https://forum.kirupa.com/t/play-tween-after-the-content-is-loaded/208508>\
**Category:** Uncategorized\
**Created:** [November 29, 2006, 2:36pm UTC](https://forum.kirupa.com/t/play-tween-after-the-content-is-loaded/208508 "2006-11-29T14:36:21Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![fr\_ode](https://avatars.discourse-cdn.com/v4/letter/f/9d8465/32.png) [@fr\_ode](https://forum.kirupa.com/u/fr_ode)\
**Post date:** [November 29, 2006, 2:36pm UTC](https://forum.kirupa.com/t/play-tween-after-the-content-is-loaded/208508/1 "2006-11-29T14:36:21Z")

</div>

My site is build up around the “The Best Structure for your Flash Site” tut. (Thank’s Mark!). Here’s the code I use to load my pages into it’s container.

Can anybody help me gettin the showContent-tween to play **after** my page is loaded?  
(In other words, when getBytesLoaded == getBytesTotal.)

```auto
function buttonClick():Void {
    _global.page = this.linkURL;
    import mx.transitions.Tween;
    import mx.transitions.easing.*;
    var hideContent:Tween = new Tween(cone.cover, "_height", Strong.easeOut, 0, 340, 0.3, true);
    hideContent.onMotionFinished = function() {
        var showContent:Tween = new Tween(cone.cover, "_height", Strong.easeOut, 340, 0, 0.3, true);
        loadMovie(_global.page, cone.content_container);
        }
}

```

I couldn’t figure out where and how to use it.

Cheers
