It could be the amount of streams you're trying to open simultaneously. Try
queuing the loading so that you only load one at a time - the overall load
time should be about the same - something like this?
var strXmlPath:String =
file1.xml,flie2.xml,file3.xml,file4.xml,file5.xml,file6.xml,file7.xml,file8
.xml,file9.xml,file10.xml;
var arrXmlPaths:Array;
var xml:XML;
function parseXML(str:String):Void
{
arrXmlPaths = str.split(,);
loadNext();
}
function loadNext ( Void ) :Void
{
xml = new XML();
xml.ignoreWhite = true;
xml.onLoad = xmlFileDoneLoading;
xml.load( arrXmlPaths.shift() );
}
function xmlFileDoneLoading():Void
{
//have all the xml files loaded?
if ( arrXmlPaths.length )
{
// no
loadNext();
}
else {
// yes, so do stuff
}
}
-Original Message-
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] On Behalf Of me myself
Sent: 22 March 2007 15:43
To: Flashcoders mailing list
Subject: [Flashcoders] Re: File works in Flash 9 player but not in 8
In case it matters, the problems occur after 11 xml files, not 10.
On 3/22/07, me myself [EMAIL PROTECTED] wrote:
Here's a really weird one: I created a Flash 8 swf -- using
Actionscript 2.0 -- compiled it as a Flash 8 swf, but it doesn't work
in the Flash 8 player. It does, however, work in the Flash 9 player.
The file loads data in from multiple xml files. It actually works
fine, even in Flash 8, if I only try to load from nine xml files, but
as-soon-as I ad a tenth file, it stops working. By stops working, I
mean that when the swf runs, I only see the Stage background.
This same swf (without being changed in any way or recompiled) works
fine in the Flash 9 player.
The 8 player doesn't seem to be balking at the amount of xml, because
if I cut the code from the tenth xml file and paste it into the 9th
file, everything works fine. It just seems to choke on ten files.
//works in Flash player 8 and 9
var strXmlPath:String =
file1.xml,flie2.xml,file3.xml,file4.xml,file5.xml,file6.xml,file7.xml
,file8.xml,file9.xml;
//works only in Flash player 9
//var strXmlPath:String =
file1.xml,flie2.xml,file3.xml,file4.xml,file5.xml,file6.xml,file7.xml
,file8.xml,file9.xml,file10.xml;
var xml:XML = new XML();
var arrXmlPaths:Array = new Array();
var arrXmlLoaders:Array = new Array(); var numXmlFilesLoaded:Number =
0;
function parseXML(str:String):Void
{
var xml:XML = new XML();
var strXml:String;
xml.ignoreWhite = true;
arrXmlPaths = str.split(,); //get list of xml files
for (var i:Number = 0; i arrXmlPaths.length; i++)
{
strXml = arrXmlPaths[i];
arrXmlLoaders[i] = new XML();
arrXmlLoaders[i].ignoreWhite = true;
arrXmlLoaders[i].onLoad = xmlFileDoneLoading;
arrXmlLoaders[i].load(strXml);
}
}
function xmlFileDoneLoading():Void
{
numXmlFilesLoaded++;
divideXmlIntoArrays(this);
//have all the xml files loaded?
if (numXmlFilesLoaded == arrXmlPaths.length)
{
parseMediaArray();
parseMediaHolderArrayAndMakeMediaHolders();
parseAndSetUpImmediateRelationships();
}
}
___
Flashcoders@chattyfig.figleaf.com
To change your subscription options or search the archive:
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders
Brought to you by Fig Leaf Software
Premier Authorized Adobe Consulting and Training http://www.figleaf.com
http://training.figleaf.com
___
Flashcoders@chattyfig.figleaf.com
To change your subscription options or search the archive:
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders
Brought to you by Fig Leaf Software
Premier Authorized Adobe Consulting and Training
http://www.figleaf.com
http://training.figleaf.com