# Passing parameters to a function

**URL:** <https://forum.kirupa.com/t/passing-parameters-to-a-function/177612>\
**Category:** flash\
**Created:** [February 3, 2006, 12:24pm UTC](https://forum.kirupa.com/t/passing-parameters-to-a-function/177612 "2006-02-03T12:24:44Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![pensamente](https://yyz1.discourse-cdn.com/flex011/user_avatar/forum.kirupa.com/pensamente/32/1208_2.png) [@pensamente](https://forum.kirupa.com/u/pensamente)\
**Post date:** [February 3, 2006, 12:24pm UTC](https://forum.kirupa.com/t/passing-parameters-to-a-function/177612/1 "2006-02-03T12:24:44Z")

</div>

anyone can find a way to say the same in just a few line of code?!  
25 lines of code people 🙂 where are u guys?!

[AS]menuAS = function () {  
//TIOCCHA  
menuBar.menu01.menu01\_btn.onRelease = function() {  
pageLOADER.loaderIndex.gotoAndStop(“menuTioccha”);  
resetMenu();  
menuBar.menu01.menu01\_btn.\_visible = 0;  
};  
//FRANCHINSING  
menuBar.menu02.menu02\_btn.onRelease = function() {  
pageLOADER.loaderIndex.gotoAndStop(“menuFranchising”);  
resetMenu();  
menuBar.menu02.menu02\_btn.\_visible = 0;  
};  
//CATALOG  
menuBar.menu03.menu03\_btn.onRelease = function() {  
pageLOADER.loaderIndex.gotoAndStop(“menuCatalog”);  
resetMenu();  
menuBar.menu03.menu03\_btn.\_visible = 0;  
};  
//STORES  
menuBar.menu04.menu04\_btn.onRelease = function() {  
pageLOADER.loaderIndex.gotoAndStop(“menuStores”);  
resetMenu();  
menuBar.menu04.menu04\_btn.\_visible = 0;  
};  
//CONTACTS  
menuBar.menu05.menu05\_btn.onRelease = function() {  
pageLOADER.loaderIndex.gotoAndStop(“menuContacts”);  
resetMenu();  
menuBar.menu05.menu05\_btn.\_visible = 0;  
};  
};[/AS]

thx
