I have this code creates a function at runtime (yes, this IS needed):
PHP Code:
var createdFunction = function():void {
    
trace("Function Created");
}

createdFunction(); 
Putting in in to the actions panel in Flash CS4 and compiling works fine, tracing the message "Function Created"...

However, the Flex compiler gives me this
Error: Call to a possibly undefined method createdFunction.
createdFunction();
Build halted with errors (fcsh).