[F8]How to access functions in external swfs and pass them variables?
Hi,
Im very close to the end of building my site, although i have one major issue i have to deal with.
Basically the homepage has links to different work in the portfolio and i need each of these to link to the correct sections of the external portfolio.swf (without having to create new swfs for each possibility...). I have a function called loadPortfolioSelection(); in the portfolio.swf:
function loadPortfolioSelection(selectedWork:String):Void {
currentPage = selectedWork;
this[selectedWork + "_mc"].gotoAndStop(7);
this[selectedWork + "Text_mc"].gotoAndPlay("_in");
mcLoader.loadClip(this[selectedWork+".swf"], this[selectedWork + "Loader_mc"]);
trace("It worked");
}
My problem is that i am unable to call this function from the main swf and pass it a variable.
My code inside home.swf is
portfolioLoader_mc.loadPortfolioSelection(page);
*The page variable holds the value i want (tested it with a trace(page))
I can't even trigger the trace command in loadPortfolioSelection(); so its obviously not executing this function. I've tried a number of different ways to execute the function but i just can't get it working.
Any help would be greatly appreciated.