Futurescale, Inc. PureMVC Home

The PureMVC Framework Code at the Speed of Thought


Over 10 years of community discussion and knowledge are maintained here as a read-only archive.

New discussions should be taken up in issues on the appropriate projects at https://github.com/PureMVC

Pages: [1]
Print
Author Topic: "Router was not set on the module" error  (Read 4321 times)
marks416
Sr. Member
****
Posts: 52


View Profile Email
« on: February 26, 2009, 01:17:34 »

Hi,

I am doing a module applicatoion with Fabrication.

I follow the url:

http://code.google.com/p/fabrication/wiki/UsingModules

and I have added the following statement to the moduleLoader instance

moduleLoader.router = applicationRouter;
moduleLoader.defaultRouteAddress = applicationAddress

What I have to do with module to fix the error.

Thanks

Mark
Logged
marks416
Sr. Member
****
Posts: 52


View Profile Email
« Reply #1 on: February 26, 2009, 02:36:52 »

Hi Darshan,

Please take a look the attached flex file that exported from flex builder. I am not sure why I get the runtime error.

Thanks

Mark

Attached file:
http://rapidshare.com/files/202955604/mdi3.zip.html
Logged
Darshan Sawardekar
Sr. Member
****
Posts: 85


View Profile Email
« Reply #2 on: March 01, 2009, 12:15:43 »

The problem is with the FlexModuleLoader usage. The applicationRouter is not set on the module loader. However the applicationRouter is created after creationComplete in Fabrication. So you will have to use it with the actionscript syntax and after fabrication is ready. I suggest doing this in/via the startup command.

peace,
darshan
Logged
marks416
Sr. Member
****
Posts: 52


View Profile Email
« Reply #3 on: March 02, 2009, 09:21:18 »

The problem is fixed after I remove mx:ModuleLoader in mxml.

Thanks

Mark
Logged
Pages: [1]
Print