# Use arrays to fire functions

**URL:** <https://forum.kirupa.com/t/use-arrays-to-fire-functions/285513>\
**Category:** Uncategorized\
**Created:** [April 1, 2009, 7:15pm UTC](https://forum.kirupa.com/t/use-arrays-to-fire-functions/285513 "2009-04-01T19:15:45Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![jeancnicolas](https://avatars.discourse-cdn.com/v4/letter/j/7bcc69/32.png) [@jeancnicolas](https://forum.kirupa.com/u/jeancnicolas)\
**Post date:** [April 1, 2009, 7:15pm UTC](https://forum.kirupa.com/t/use-arrays-to-fire-functions/285513/1 "2009-04-01T19:15:45Z")

</div>

Can I store function names in arrays, which then can be used to fire those functions when that array value is called?  
So basically - I mouse click, and that += 1 to my num var.

```auto
var myF:Array = new Array("thisone","thatone");
var num:Number = 0;
function thisone()
{
/////do whatever/////
}
onEnterFrame = function()
{
////////fire the function named as the array states!///////
myF(num)
}
MouseListener.onMouseDown = function(){
num ++;
}

```

I dont know how to make a function call from a string value! Get me??  
Help would be ace!
