# addFrameScript + Arguments in call function

**URL:** <https://forum.kirupa.com/t/addframescript-arguments-in-call-function/239313>\
**Category:** flash\
**Created:** [September 20, 2007, 1:03pm UTC](https://forum.kirupa.com/t/addframescript-arguments-in-call-function/239313 "2007-09-20T13:03:44Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![parxal](https://avatars.discourse-cdn.com/v4/letter/p/4da419/32.png) [@parxal](https://forum.kirupa.com/u/parxal)\
**Post date:** [September 20, 2007, 1:03pm UTC](https://forum.kirupa.com/t/addframescript-arguments-in-call-function/239313/1 "2007-09-20T13:03:44Z")

</div>

How can i pass arguments to the function that i call in addFrameScript ?

This does not work:

mc.addFrameScript(mc.totalFrames-1,myFunction(2));

private function myFunction(e:int):void  
{  
trace(e);  
}

The function is called on the first Frame, and is not called again!

Thanks
