MegaZine3 Version 2 > Technical Support (AS3 / JS / ASUL)
Dynamically loading mz3 file only works once
(1/1)
Kotch:
I am using version 2.0.10 (though am on verge of upgrading to the latest version as I'm pulling my hair out with all the Megazine problems I am having).
I used the megazine 'load' function to dynamically load my mz3 file. As follows:
megazine.load( contentID + ".mz3");
To remove content I call:
megazine.dispose();
But when I call the 'load' function again:
megazine.load( contentID + ".mz3");
Nothing happens the second time round. Do you know why?
I noticed that someone else had a simlar problem:
http://www.megazine3.de/forum/index.php/topic,1325.msg5206.html#msg5206
Florian Nücke:
Is the 'megazine' in the second call a new instance? The dispose method will make the first one unusable (it cannot be used multiple times).
Kotch:
Hello Florian
Thanks for that info.
I was hoping to be able to clear the current loaded in mz3 file/page content and load in a new one without having to create a new Megazine instance. I can see thats not possible now.
Cheers.
Kotch:
My project contains 4 newspapers to flick through. At the moment I am creating a Megazine instance whenever a newspaper is launched and disposing of it when the newspaper is closed. Only one Megazine instance is in existence at one time.
However, the page turning seems to become less responsive the more I create and dispose of a Megazine instance. Why could this be?
Would a better approach be to create 4 instances at once, never disposing of them just displaying/hiding as required?
Navigation
[0] Message Index
Go to full version