Just kidding..kinda.. After googling a lot of combination of terms, I
was able to finally get some answers regarding problems that seem to
come up while trying to develop a modular application, but, sadly, I am
not 100% sure what the Adobe person was talking about. The error always
centers around the mysterious error: 'ArgumentError: Error #2004: One of
the parameters is invalid. at flash.display::Graphics/drawRoundRect()...'
More often than not it revolves around a <s:Button> but I just got the
same error on a layout that has no buttons. This time it seems to
revolve this time be a <s:BorderContainer> since when I swapped it out
from a <s:Group> (which worked fine) it started throwing errors.
My question to the group is how to manage loading Modules from the
application and not throw errors? Why does this happen when it never did
it in 3.4. I read it has to do with Style references with the main
application, but, again, I don't know exactly what that means or how to
fix it.
Since it seems to come up in the other posts I could find, I have an
Application that, based on a log in and the user's 'accountType', loads
a modules for that user's portal type. I use this to load the modules,
which seems to be pretty stock, and it works fine for the loading and
adding of different modules throughout the application.:
private function loadModule(path:String):void {
modLoader = ModuleManager.getModule(path);
modLoader.addEventListener(ModuleEvent.ERROR,
modErrorHandler);
modLoader.addEventListener(ModuleEvent.READY,
modReadyHandler);
modLoader.load();
}
private function modErrorHandler(e:ModuleEvent):void {
Alert.show("Module did not load correctly", "Module
Loading Error");
}
private function modReadyHandler(e:ModuleEvent):void {
this.removeAllElements();
this.addElement(modLoader.factory.create() as
IVisualElement);
}
Any ideas why I get that error when loading modules? How can I fix it?
Does ANYONE know why that error is thrown?