Jump to content


Dynamically Assign urlOrRequest

Moderator Tag

Recommended Posts

Greetings from Boise,
I'd like to create a single Instance of LoaderMax.
I'd like to use that Instance to call one of several .swf's to load, dynamically, via a MouseEvent.
myLoader.urlOrRequest = "myURL.swf" throws an 1119: "Access of possibly undefined property urlOrRequest through a reference with static type com.greensock.loading.SWFLoader."
What am I missing, please?
Thanks ahead of time!

case this.palmer_Aerial.eastBuildingAerial:
    changeLoader.urlOrRequest = "eastBuilding.swf"
Link to comment
Share on other sites

G'day mate,


Unless I'm mistaken, I think LoaderMax is just for including other loaders and then loading them in that way. Instead of using a loaderMax instance, if all your are doing is loading in SWF's you could just use a SWFLoader and change and load the url that way.


Something along the lines of this should work:

//First create an instance of your SWF Loader
			var swf:SWFLoader = new SWFLoader("", { container:yourSWFContainer } );
			//Then in your case statements set the url
			swf.url = "pathToYourSWF.swf";
			//Then after your case statement load the swf content
Link to comment
Share on other sites

I'll try that-thank you very much for your help! And yeah, I don't know why I referenced LoaderMax being that I'm Instantiating SWFLoader. My advice: don't get old!



  • Like 1
Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    • No registered users viewing this page.