Skip navigation
Frerich Raabe
Currently Being Moderated

When would ApplicationDomain.hasDefinition yield false for a valid class name?

Feb 26, 2013 8:38 AM

Tags: #flex

I'm using Flash Player 11.5 and just hit a case in whic ApplicationDomain.hasDefinition() yields false (and ApplicationDomain.getDefinition() raises a ReferenceError) for any string in the vector returned by ApplicationDomain.getQualifiedClassNames().

 

The scenario: I'm using the "PreloadSwf" mechanism to load a small .swf file. In this, I'm using SWFLoader to load another swf file and then try to instantiate a type in that second swf - this fails. The application domain object is the one on the 'content' object given by the SWFLoader. If I call 'getQualifiedClassNames()' on it, I get plenty of types, but calling 'hasDefinition()' on any of those types yields false. Does anybody know why that is?

 

A matter of build flags maybe?

 
Replies
  • Currently Being Moderated
    Feb 26, 2013 1:40 PM   in reply to Frerich Raabe

    Show the code that acquires the ApplicationDomain object.  It is easy to not be in the correct ApplicationDomain context.

     
    |
    Mark as:

More Like This

  • Retrieving data ...

Bookmarked By (0)

Answers + Points = Status

  • 10 points awarded for Correct Answers
  • 5 points awarded for Helpful Answers
  • 10,000+ points
  • 1,001-10,000 points
  • 501-1,000 points
  • 5-500 points