1 Reply Latest reply on Jul 14, 2008 5:01 PM by ntsiii

    Pass a function as a parameter

      Hi all,

      I have a standard HTTPService call, but the following doesn't work: <mx:HTTPService ... request="MyClass.something.function();"></mx:HTTPService> (says .function(); is not a variable, but I'm trying to get it to access a public function!). MyClass.something.function() returns an XML Object, so how can I get this to work properly? Any help would be appreciated! Thanks!
        • 1. Re: Pass a function as a parameter
          ntsiii Level 3
          Do that in an AS function so you can debug it.

          This is probably a timing issue where MyClass is not instantiated when the assignment happens.

          Another reason to do it in a function, you can call that fucntion on creationComplete, and be mostly assured that your object exists.