# Standard way to run the same code on multiple instances?

**URL:** <https://forum.kirupa.com/t/standard-way-to-run-the-same-code-on-multiple-instances/317313>\
**Category:** flash\
**Created:** [December 16, 2010, 3:47pm UTC](https://forum.kirupa.com/t/standard-way-to-run-the-same-code-on-multiple-instances/317313 "2010-12-16T15:47:16Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![BadBoyMcCoy](https://avatars.discourse-cdn.com/v4/letter/b/bbe5ce/32.png) [@BadBoyMcCoy](https://forum.kirupa.com/u/BadBoyMcCoy)\
**Post date:** [December 16, 2010, 3:47pm UTC](https://forum.kirupa.com/t/standard-way-to-run-the-same-code-on-multiple-instances/317313/1 "2010-12-16T15:47:16Z")

</div>

Hi all, quick question from an as2 newby.

I’m creating a navigation menu, as the cursor hovers over each of the menu items I want them to behave in a certain way. They all behave the same way but obviously the text is different… So basically I was wondering what’s the best way to apply the same code to multiple instances, without repeating the code?

TIA  
Cian
