[Extendflash] How to include another file of functions in a command

Judah Frangipane judah-fc at t8design.com
Mon Aug 1 14:28:08 PDT 2005


Thanks Wade!

Wade Arnold wrote:

> To my understanding there is no way to include or extend a JSFL file?  
> Please post if this is not correct as I would love to know this too!  
> All that you can really do is run an external script. By doing this 
> you  then have access to the functions in that external script.
>
> fl.runScript( fileURI [, funcName [, arg1, arg2, ...] ])
>
> http://livedocs.macromedia.com/flash/mx2004/main_7_2/wwhelp/wwhimpl/ 
> common/html/wwhelp.htm?context=Flash_MX_2004&file=00003371.html
>
> Here is an example.
> http://www.mediasparkles.com/2004_02_01_archives.html#107724281417051885
>
>
> Wade
>
>
>
> On Jul 26, 2005, at 2:40 PM, Judah Frangipane wrote:
>
>> I have a lot of utility functions I use in my jsfl commands. I'd 
>> like  to put them in an external file and include them in the scripts 
>> I  create.
>>
>> I did this and the functions do not get called from the main script  
>> but variables do. Is this the case with anyone else?
>>
>> //*******************
>> // in utilities file
>> myObj = new Object();
>> myObj.myFunc = function() {
>>
>> }
>> function myFunc2() {
>>
>> }
>>
>> //*******************
>> // in main file
>> fl.runScript(utilitiesFilePath);
>> alert("myObj=" + myObj); //[object Object]
>> alert("myObj.myFunc =" + myObj.myFunc); // exists
>> alert("myFunc2=" + myFunc2); // throws error "ReferenceError: 
>> myFunc2  is not defined"
>>
>> Best Regards,
>> Judah
>> _______________________________________________
>> Extendflash mailing list
>> Extendflash at flashguru.co.uk
>> http://lists.flashguru.co.uk/mailman/listinfo/extendflash
>>
>>
>
> _______________________________________________
> Extendflash mailing list
> Extendflash at flashguru.co.uk
> http://lists.flashguru.co.uk/mailman/listinfo/extendflash
>
>
>



More information about the Extendflash mailing list