# gotoAndStop() for DisplayObjectContainer

**URL:** <https://forum.kirupa.com/t/gotoandstop-for-displayobjectcontainer/272087>\
**Category:** flash\
**Created:** [October 1, 2008, 10:38pm UTC](https://forum.kirupa.com/t/gotoandstop-for-displayobjectcontainer/272087 "2008-10-01T22:38:55Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![HMPoweredMan](https://avatars.discourse-cdn.com/v4/letter/h/57b2e6/32.png) [@HMPoweredMan](https://forum.kirupa.com/u/HMPoweredMan)\
**Post date:** [October 1, 2008, 10:38pm UTC](https://forum.kirupa.com/t/gotoandstop-for-displayobjectcontainer/272087/1 "2008-10-01T22:38:55Z")

</div>

I have a class called Robot that is an extension of a movieclip of a robot walking animation. It has two frames. A robotLeft frame and a robotRight frame.

Now this Robot Class has a child called robotHitbox that does all the “thinking” for the robot. but when I try to get the robotHitbox the change it’s parent’s current frame with gotoAndStop(“robotRight”) I get this error.

```auto

1061: Call to a possibly undefined method gotoAndStop through a reference with static type flash.display:DisplayObjectContainer.

```

Is a DisplayObjectContainer no longer a MovieClip? Am I unable to change its current frame once it has children?
