# Multiple movieclips, 3 functions with unique targets

**URL:** <https://forum.kirupa.com/t/multiple-movieclips-3-functions-with-unique-targets/272168>\
**Category:** Uncategorized\
**Created:** [October 2, 2008, 3:41pm UTC](https://forum.kirupa.com/t/multiple-movieclips-3-functions-with-unique-targets/272168 "2008-10-02T15:41:02Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![convrgr](https://avatars.discourse-cdn.com/v4/letter/c/ba9def/32.png) [@convrgr](https://forum.kirupa.com/u/convrgr)\
**Post date:** [October 2, 2008, 3:41pm UTC](https://forum.kirupa.com/t/multiple-movieclips-3-functions-with-unique-targets/272168/1 "2008-10-02T15:41:02Z")

</div>

(cs3,as2)  
I was wondering if there’s an easier way of getting these functions to work for about 150 different buttons? I just put three of the blocks of code in here to show you what it looks like across more than one. On the gotoAndStop actions, the name is a frame label on a seperate swf file. the name used everywhere else is an instance name on a dynamic textbox located inside a movieclip. All this script is located in an external .as file. Thanks so much for reading.

aaronkotowski.fade.person.text = “Aaron Kotowski”;  
aaronkotowski.onRollOver = function() {  
gotoAndStop(“aaronkotowski”);  
aaronkotowski.fade.person.textColor = 0x666666;  
};  
aaronkotowski.onRelease = function() {  
getURL(“[http://www.aaronkotowski.com](http://www.aaronkotowski.com)”, “\_blank”);  
};  
aaronkotowski.onRollOut = function() {  
aaronkotowski.fade.person.textColor = 0xffffff;  
};

albertnormandin.fade.person.text = “Albert Normandin”;  
albertnormandin.onRollOver = function() {  
gotoAndStop(“albertnormandin”);  
albertnormandin.fade.person.textColor = 0x666666;  
};  
albertnormandin.onRelease = function() {  
getURL(“[http://www.albertnormandin.com](http://www.albertnormandin.com)”, “\_blank”);  
};  
albertnormandin.onRollOut = function() {  
albertnormandin.fade.person.textColor = 0xffffff;  
};

aliciarose.fade.person.text = “Alicia Rose”;  
aliciarose.onRollOver = function() {  
gotoAndStop(“aliciarose”);  
aaronkotowski.fade.person.textColor = 0x666666;  
};  
aliciarose.onRelease = function() {  
getURL(“[http://www.aliciajrosephotography.com/](http://www.aliciajrosephotography.com/)”, “\_blank”);  
};  
aliciarose.onRollOut = function() {  
aliciarose.fade.person.textColor = 0xffffff;  
};
