Uploaded image for project: 'Apache Flex'
  1. Apache Flex
  2. FLEX-23703

calling submodule method receives runtime error:ypeError: Error #1009: Cannot access a property or method of a null object reference.

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Major
    • Resolution: Not A Problem
    • Adobe Flex SDK 4.1 (Release)
    • None
    • Modules
    • None
    • Affected OS(s): All OS Platforms
      Language Found: English

    Description

      Steps to reproduce:
      1. compile and run test file(bug26163.mxml)
      2. click "load Module1" button(it tries to load a module M1 which loads another module: M2).
      3. when sub module UI(M2) shows up, click "compute" button

      Actual Results:
      receive RTE:
      TypeError: Error #1009: Cannot access a property or method of a null object reference.

      The issue is after module(M1) loads sub module(M2), when it tries to get the module instance with statment like this:
      sm=assetModule.factory.create() as SimpleModule;

      it returns null, however assetModule.factory.create() returns [object SimpleModule].

      Expected Results:
      no such error.

      Workaround (if any):
      no try to convert IModuleInfo.factory.create(), not sm=assetModule.factory.create() as SimpleModule;

      instead use sm=assetModule.factory.create(); then access methods of SimpleModule.

      Attachments

        Activity

          People

            adobejira Adobe JIRA
            adobejira Adobe JIRA
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: