@#{!^[(§# Flash - sending variables with loadmovie

Why does everything in Flash have to be such a pain in the ***? You think you’re going to do something simple in 5 seconds of typing, but half of the times it turns out you’re wasting hours searching for a way around some stupid restriction of flash.

This time I made a movie that uses some variables that are specified in the .html (FlashVars). Sending these variables from html to the flash movie is no problem.
But I tried to see if my movie still works when it’s loaded into a holder movieclip. So I use the following code to load the movie and send the same variables to it:

mc_holder.loadMovie("imageviewer.swf?width=700&height=350&imageList=afbeeldingen.txt&settings=ivsettings1.xml");

Should be easy enough, but it doesn’t work.

Error opening URL “file:///D|/%5FOPDRACHTEN/%5FIMAGEVIEWER/ImageViewer/imageviewer.swf? width=700&height=350&imageList=afbeeldingen.txt&settings=ivsettings1.xml”

So I tried this:

mc_loader.width="700";
mc_loader.height="350";
mc_loader.imageList="afbeeldingen.txt";
mc_loader.settings="ivsettings1.xml";
mc_loader.loadMovie("imageviewer.swf", "GET");

Which returns this:

Error opening URL “file:///D|/%5FOPDRACHTEN/%5FIMAGEVIEWER/ImageViewer/imageviewer.swf? width=700&height=350&imageList=afbeeldingen**%2Etxt&settings=ivsettings1%2E**xml”

(notice the %2E where a period should be)

When I leave out the variables like this, it loads the movie, but without the variables of course.

mc_loader.loadMovie("imageviewer.swf");

Anybody have an idea on how to find a way that works?

Please!

You’re sending Vars from a SWF directly to another SWF. I don’t know if that works.

have you tried using the full url path to the file? Like this:

mc_holder.loadMovie("http://www.somewebsite.com/imageviewer.swf?width=700&height=350&imageList=afbeeldingen.txt&settings=ivsettings1.xml");