# DisplayObject dispath event

**URL:** <https://forum.kirupa.com/t/displayobject-dispath-event/321161>\
**Category:** flash\
**Created:** [April 12, 2011, 10:41am UTC](https://forum.kirupa.com/t/displayobject-dispath-event/321161 "2011-04-12T10:41:26Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![acrylics](https://avatars.discourse-cdn.com/v4/letter/a/3e96dc/32.png) [@acrylics](https://forum.kirupa.com/u/acrylics)\
**Post date:** [April 12, 2011, 10:41am UTC](https://forum.kirupa.com/t/displayobject-dispath-event/321161/1 "2011-04-12T10:41:26Z")

</div>

I embeded a png format picture and set class like Axe:Class;,and set a variable like pic:DisplayObject,and point pic to an object,var pic=new Axe();  
added it to the display list:addChild(pic);  
then i added the eventListener, pic.addEventListener(MouseEvent.Click,\_doSomeThing);  
private function \_doSomeThing(e:MouseEvent):void{  
//process  
}

but nothing happens,the complier doesn’t report an error or warning something.  
then i created a wrapper Sprite object and add the pic to the wrapper object,made the wrapper object as the event dispatcher,then every thing works.As far as i know,DisplayObject is added to the stage,but why it doesn’t work?this is weird, PLEASE HELP.
