1 Reply Latest reply on May 23, 2007 9:26 AM by kglad

    Creating Application Domain

    MaxVT103 Level 1
      Ok, I am trying to create an application domain to get the system domain. I looked in the actionscript 3.0 language reference and saw that ApplicationDomain had a constructor function which states:


      public function ApplicationDomain(parentDomain:ApplicationDomain = null);
      Creates a new application domain.
      parentDomain:ApplicationDomain (default = null) — If no parent domain is passed in, this application domain takes the system domain as its parent.

      However when I try to compile I get error 1007:

      TypeError: Error #1007: Instantiation attempted on a non-constructor.

      So how do I create the instance correctly?