# Quick question about accessing a movieclip!

**URL:** <https://forum.kirupa.com/t/quick-question-about-accessing-a-movieclip/265949>\
**Category:** Uncategorized\
**Created:** [July 14, 2008, 9:15pm UTC](https://forum.kirupa.com/t/quick-question-about-accessing-a-movieclip/265949 "2008-07-14T21:15:40Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![panopticon\_](https://avatars.discourse-cdn.com/v4/letter/p/a3d4f5/32.png) [@panopticon\_](https://forum.kirupa.com/u/panopticon_)\
**Post date:** [July 14, 2008, 9:15pm UTC](https://forum.kirupa.com/t/quick-question-about-accessing-a-movieclip/265949/1 "2008-07-14T21:15:40Z")

</div>

so im inside my movieclip called “blah” (instance name the same), and i’m writing some code in the timeline of “blah”.

with this code i want to tween a movieclip (called “info”, instance name also “info”) which is directly on the stage (not in the movieclip “blah”)

i tried

```auto

TweenLite.to(_root.info, 3, {alpha:0});

```

and

```auto

TweenLite.to(stage.info, 3, {alpha:0});

```

but i cant get it to work. how do i do it? its quite urgent, thank you for your help 😉

hierarchy:

```auto

|------my stage 
          |--------scrollbox_main (MovieClip)
                               |----------blah (MovieClip)

          |--------info

```

“info” is on the same level as “scrollbox\_main” and i want do access it out of “blah”

---

<div class="post-metadata">

**Author:** ![panopticon\_](https://avatars.discourse-cdn.com/v4/letter/p/a3d4f5/32.png) [@panopticon\_](https://forum.kirupa.com/u/panopticon_)\
**Post date:** [July 15, 2008, 7:48am UTC](https://forum.kirupa.com/t/quick-question-about-accessing-a-movieclip/265949/2 "2008-07-15T07:48:56Z")

</div>

i read a tip from senocular, i think its about my problem

> **[ActionScript 3 Tip of the Day - Page 15](https://www.kirupa.com/forum/showthread.php?223798-ActionScript-3-Tip-of-the-Day&s=7fe392882125a2ceec87248c4f49b1a4&p=1952513#post1952513)**
>
> Got a web design/development question or just want to hang out with the most awesome people on the planet? Drop on in!

but i just dont get it … i dont know how to use this for my project ☹

---

<div class="post-metadata">

**Author:** ![hasch2o](https://avatars.discourse-cdn.com/v4/letter/h/ba8739/32.png) [@hasch2o](https://forum.kirupa.com/u/hasch2o)\
**Post date:** [July 15, 2008, 8:01am UTC](https://forum.kirupa.com/t/quick-question-about-accessing-a-movieclip/265949/3 "2008-07-15T08:01:51Z")

</div>

try

```auto

TweenLite.to(parent.getChildByName("info"), 3, {alpha:0});

```

don’t have flash here, but should work…maybe a typo or so.

hth  
Carlo

---

<div class="post-metadata">

**Author:** ![panopticon\_](https://avatars.discourse-cdn.com/v4/letter/p/a3d4f5/32.png) [@panopticon\_](https://forum.kirupa.com/u/panopticon_)\
**Post date:** [July 15, 2008, 8:07am UTC](https://forum.kirupa.com/t/quick-question-about-accessing-a-movieclip/265949/4 "2008-07-15T08:07:26Z")

</div>

this code works:

```auto

TweenLite.to(parent.parent.getChildByName("info"), 3, {alpha:0});

```

thank you!

but why does “TweenLite.to(parent.parent.info, 3, {alpha:0});” not work?? just curious…

---

<div class="post-metadata">

**Author:** ![hasch2o](https://avatars.discourse-cdn.com/v4/letter/h/ba8739/32.png) [@hasch2o](https://forum.kirupa.com/u/hasch2o)\
**Post date:** [July 15, 2008, 8:11am UTC](https://forum.kirupa.com/t/quick-question-about-accessing-a-movieclip/265949/5 "2008-07-15T08:11:18Z")

</div>

Happy that It works.

if you enter parent.parent.info flash expects a variable called info in the object parent.parent (which would be your stage) but you don’t have an variable called info which represents a Movieclip there, that’s why flash has no idea what to do.  
If you want to address a displayobject by name you always have to use getChildByName which returns a reference to the displayobject.

(Hope I didn’t say to much crap here, fairly new with AS3 myself)

Cheers carlo
