Hi, I’ve got a movie where I duplicate a Button a bunch of times using the DuplicateMoiveClip command. This works fine and dandy.
however I now need (on the rollover) for each button to know its name, but “_name” gives the name of the instance, and since these buttons were created dynamically, the instance name is not created. And when a Trace is put on the “_name” on the rollover state of the generated btn it gives me the name of the movie clip that the button is in (so all the buttons have the same name)
1- is there some way to define the instance name of a generated symbol?
2- can I pull the name from the actuall name of the symbol?
Ok this is the code for creating the Buttons (it takes the first button, duplicates it, moves it over 10px, does this till the row is full, then continues till the grid is full… and it works lovley)
What I need is when you rollover the newly made buttons, I need it to know who it is…
if I use this code
on (rollOver) {
trace(this._name);
}
I get the name of the instance for the movie the buttons are in
if I use
on (rollOver) {
trace(_name);
}
I get the same thing
how can I get the property of the name of the button that I’m rolling over?
getProperty(this,_Name);
also gives the name of the movieclip that they reside in, not the button.
(keeping in mind that these buttons are created with the duplicate clip function, so I cannot give them an instance name (or if I can I dont know how to)