# Get instance name and position

**URL:** <https://forum.kirupa.com/t/get-instance-name-and-position/274726>\
**Category:** flash\
**Created:** [November 3, 2008, 5:37pm UTC](https://forum.kirupa.com/t/get-instance-name-and-position/274726 "2008-11-03T17:37:44Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![bmb](https://avatars.discourse-cdn.com/v4/letter/b/54ee81/32.png) [@bmb](https://forum.kirupa.com/u/bmb)\
**Post date:** [November 3, 2008, 5:37pm UTC](https://forum.kirupa.com/t/get-instance-name-and-position/274726/1 "2008-11-03T17:37:44Z")

</div>

I have 3 buttons and when i click the button i need to know is position and is instance name… I try this to get the name. But the trace was allways “root1”.

```auto
bt1.addEventListener(MouseEvent.MOUSE_OUT, nameObject);
bt2.addEventListener(MouseEvent.MOUSE_OUT, nameObject);
bt3.addEventListener(MouseEvent.MOUSE_OUT, nameObject);

function nameObject(Event:MouseEvent) {
	
	trace(""+ this.name);
	}

```

Cam someone help me?

thanks
