08-20-2012 10:37 PM
I have been trying to load an image, and I keep getting URL Not Found error.
I am using background.setImage("image.png");
I have the image under the project folder, and under the src folder.
Is there something I am missing?
Solved! Go to Solution.
08-20-2012 10:55 PM
Can you post a code snippet, if your code is not so proprietary as to preclude publically posting it?
For loading an image file from a local app directory using a URLRequest object the typical usage is e.g.:
myURLRequest = new URLRequest("app:///<relative path to image file>");
Some folks like to segregate their assets into separate dirs so you might have a path like
You would create a URLRequest object as above and then use the load() method of a Loader object to
load the URL, and once it loaded successfully, access the ContentLoaderInfo.content property of the