There have been some reports of runtime errors when Applications are loading multiple sub-applications (such as Modules and/or PopUps) from a single Application. One of the bugs with an example that I uploaded can be found here: SDK-13152. In the sample bugfile included with this bug, you can create a popup from a loaded module with no problem. However, once you unload the module and re-load it, you will get an error when attempting to create a popup from that module. The runtime error that you will get is:
TypeError: Error #1034: Type Coercion failed: cannot convert mx.managers::PopUpManagerImpl@13068c1 to mx.managers.IPopUpManager.
at mx.managers::PopUpManager$/get impl()
To get around this error, you need to include the IPopUpManager class in your main Application:
private var iPopUpManager:IPopUpManager;
According to our developers, because of the design of the SingletonManager that supports a bootstrap topology, any time you get into a similar topology (where multiple sub-applications are loaded in a main Application), you need to move shared interfaces into the bootstrap. In this case it is the IPopUpManager, which we can be moved into the main application (effectively the bootstrap) via this two-line workaround.
A similar bug is reported with multiple sub-applications using the DragManager. Details can be found in SDK-995. In this scenario, the Application loaded different swfs using the SWFLoader into various views of a TabNavigator. These swfs both included a DataGrid using the DragManager. To get around the error, the Application needed to include:
private var iDragManager:IDragManager;