Can i ask if you are loading the same module into each 'stub'?

i.e. do you have a multi-purpose module that is loaded 4 times 
(SubmissionModule.swf)?

I had a problem with loading a single multi-purpose module more than 
once.  I was dynamically loading n modules that contained a number of 
hyperlinks.

The problem was that the 2nd module was being loaded before the 1st 
one was ready, resulting in the 1st module being garbage collected, 
and therefore never loading.

Let me know if this helps.

Barry

--- In flexcoders@yahoogroups.com, "jamison_wilde" 
<[EMAIL PROTECTED]> wrote:
>
> I'm having a lot of issues with ModuleLoader only occasionally 
loading
> my modules.  At first I thought maybe it was that I couldn't have 
the
> module open in more than one tab at a time in my browser, as this
> seemed to help a little.  But it seems more like there is a basic
> problem with loading multiple modules at once.
> 
> Basically in my main mxml I have:
>       <mx:Canvas id="views_canvas" x="10">
>               <views:PrizesStub id="prizes" visible="false" />
>               <views:Home id="home" visible="false"/>
>               <views:ListStub id="list" visible="false" />
>               <views:SubmissionStub id="submission" 
visible="false" />
>       </mx:Canvas>
> 
> where the stubs are stub components for the modules, so they can 
hold
> data that might be needed before the module is loaded.
> 
> One of my stubs looks like:
> <?xml version="1.0" encoding="utf-8"?>
> <mx:Canvas xmlns:mx="http://www.adobe.com/2006/mxml";>
>               <mx:ModuleLoader id="module" 
url="views/SubmissionModule.swf" />
> </mx:Canvas>
> 
> 
> That's pretty much it. The SubmissionModule will only load once 
every
> 4 or 5 times I debug.  I've tried adding unique identifiers to the 
url
> like:
>               <mx:ModuleLoader id="module" 
url="{'views/SubmissionModule.swf?uid='
> + new Date().getTime()}" />
> 
> but that doesn't seem to help.
> 
> The ready event never fires when it doesn't work.
> 
> The only thing I can think of is that it is loading all of the 
Modules
> at once(once the main swf has loaded) even though the views that
> contain them aren;t visible.  Is there some reason that shouldn't
> happen or would cause a problems?
>


Reply via email to