# Convert instance name to string

**URL:** <https://forum.kirupa.com/t/convert-instance-name-to-string/291895>\
**Category:** Uncategorized\
**Created:** [July 7, 2009, 9:14am UTC](https://forum.kirupa.com/t/convert-instance-name-to-string/291895 "2009-07-07T09:14:05Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![udi001](https://avatars.discourse-cdn.com/v4/letter/u/bc8723/32.png) [@udi001](https://forum.kirupa.com/u/udi001)\
**Post date:** [July 7, 2009, 9:14am UTC](https://forum.kirupa.com/t/convert-instance-name-to-string/291895/1 "2009-07-07T09:14:05Z")

</div>

hi,

i have several button that should navigate to frames in my movie.  
the button have the same name as the frame’s labels

i need to convert the buttons’ instance names to strings

> 

stop();  
import flash.events.MouseEvent;

this.Label1.addEventListener(MouseEvent.MOUSE\_DOWN,gotoLabel);

function gotoLabel(event:MouseEvent):void{

gotoAndStop(‘label1AsString’);  
}
