Preloading multiple swf files

Hi, i’m browsing true this forums for some days now, and yes there are many preloaders out there, but i can’t really find one that works for me.

first off, i’m not good with english and 2nd i’m not that good with actionscript either, i can understand code to some degree, but i’m more of a copy/paster.

my site pretty much work like a slide show. the navigation (6 buttons) takes you from
one place to another, moving the content back and forward. The problem with this, is that pretty much all content have to be loaded from start, sometimes when the page loads slow or you are on a bad connection, you get transported to a blank page, since that swf haven’t been loaded yet. Hope you guys understand my site now. I’ll give you my structure also.

index.swf ( movieclip (contentHolder_mc) that loads all the content, basic layout,
| navigation buttons (home, about, products, video, faq, contact) )
|
|_ home10.swf ( content first page, HOME )
|_ **about20.swf **( content 2nd page, ABOUT )
|_ **products30.swf **( content 3rd page, PRODUCTS, also 4 submenys, navigation works
| | the same way, slideshow back and forward )
| |
| |_ products31.swf (content)
| |_ products32.swf (content)
| |_ products33.swf (content)
|
|_ **animation40.swf **( content 4th page, ANIMATION, also 4 submenys)
| |
| |_ animation41.swf (content)
| |_ animation42.swf (content)
| |_ animation43.swf (content)
|
|_ **faq50.swf **(content 5th page, FAQ)
|_ **contact60.swf **(content 6th page, CONTACT, 2 sub menys)
[COLOR=white]|[/COLOR] |
[COLOR=white]|[/COLOR] |_ contact61.swf (content)
[COLOR=white]|[/COLOR] |_ contact62.swf (content)

in index.swf they are loaded true true a movieclip called contentHolder_mc:

 
loadMovie("home10.swf", contentHolder_mc.contentHome_mc);
loadMovie("about20.swf", contentHolder_mc.contentAbout_mc);
loadMovie("products30.swf", contentHolder_mc.contentProducts_mc);
loadMovie("animation.swf", contentHolder_mc.contentAnimation_mc);
loadMovie("faq50.swf", contentHolder_mc.contentFaq_mc);
loadMovie("contact60.swf", contentHolder_mc.contentContact_mc);

and for fun i’m posting the tweens also, so you get a hang of the way the navigation works.

 
mProducts_btn.onRelease = function() {
 var xProducts:Tween = new Tween(contentHolder_mc, "_x", Strong.easeInOut, contentHolder_mc._x, -1200, 2, true);
};

Now to my question, problem.

I need to make a preloader for this, that loads all external swf’s at the very first frame with a typical progressbar, for ALL the content, not for every single swf.

my dream solution would be.

at first frame, a basic progressbar pops up (0 to 100%) when 100% it goes to frame 2 and the site is revealed/loaded. at the moment i got a working preloader for this, but i can’t get it to load all the external swf files.

posting code here, as you see this wont work:

 
onClipEvent (enterFrame) {
 loaded = _parent.getBytesLoaded();
 total = _parent.getBytesTotal();
 progress = Math.round((loaded/total)*100);
 loaderInfo = Math.round((loaded/total)*100) + " % LOADING";
 progressBar._width = progress*2;
 if (loaded == total) {
  _parent.gotoAndPlay(2);
 }
}

while i was browsing the site i found this, made by a guy named scotty, that looked very cool, but to bad i didnt fully understood it.

var k = 0;
swfs = new Array("sendo10.swf", "sendo20.swf", "sendo30.swf", "sendo31.swf", "sendo32.swf", "sendo33.swf", "sendo40.swf", "sendo41.swf", "sendo42.swf", "sendo43.swf", "sendo50.swf", "sendo60.swf", "sendo61.swf", "sendo62.swf", "sendo63.swf");
function preloadSwf() {
    var con = container.duplicateMovieClip("con"+k, 9984+k);
    con.loadMovie(swfs[k]);
    var temp = this.createEmptyMovieClip("temp"+k, 99+k);
    temp.onEnterFrame = function() {
        info.text = "Loading "+swfs[k];
        if (con._width) {
            con._visible = 0;
            nextSwf();
            delete this.onEnterFrame;
        }
    };
}
function nextSwf() {
    if (k<swfs.length-1) {
        k++;
        preloadSwf();
    } else {
        con0._visible = 1;
    }
 

If i could combine these two scripts, i think i could get the solution i’m looking for. Or do you guys strongly disagree or is there a simpler way? Need all the help i can get, thx in advance.

// best regards Daniel