3 Replies Latest reply on Aug 15, 2014 5:06 AM by Ned Murphy

    TypeError #1009

    emanJD Level 1

      I'm working a simple game just to test how to link both preloader and game swf file.everything seems to work fine, expect when i try linking both files together I get the error "

      TypeError: Error #1009: Cannot access a property or method of a null object reference. at Game() " . When I use image files instead of swf it works.


      Please Help.

        • 1. Re: TypeError #1009
          Ned Murphy Adobe Community Professional & MVP

          The 1009 error indicates that one of the objects being targeted by your code is out of scope.  This could mean that the object....


          - is declared but not instantiated

          - doesn't have an instance name (or the instance name is mispelled)

          - does not exist in the frame where that code is trying to talk to it

          - is animated into place but is not assigned instance names in every keyframe for it

          - is one of two or more consecutive keyframes of the same objects with no name assigned in the preceding frame(s).


          When loadfing one file into another it is likely that the file producing the error has alost a reference point and is no longer able to target an object that it could as a standalone file.


          If you go into your Publish Settings Flash section and select the option to Permit debugging, your error message should have a line number following the frame number which will help you isolate which object is involved.

          1 person found this helpful
          • 2. Re: TypeError #1009
            emanJD Level 1

            thank you it works now.

            • 3. Re: TypeError #1009
              Ned Murphy Adobe Community Professional & MVP

              You're welcome