Hey there. I am running into an annoying problem with Flash, particularly when I run my program in Debug. Basically I have an AS3 project at some location on my computer (c:/.../Flash/Project/project.fla) with a main script for it (c:/.../Flash/Project/code/projectMain.as). If I try to load in SWF files or JPG files from other places on my computer, I get problems. For example if I try to load files like:
It seems to load them fine. When I click on the movie though, I get this in the output:
*** Security Sandbox Violation ***
SecurityDomain 'file:///C/.../file.swf' tried to access incompatible context 'file:///C/.../project.swf
And the whole thing stops working. I have read about the security sandbox and allowDomain calls and all that, but I don't see how the domains are different. I am not deploying this to any server or anything, just trying to run the debug swf. I have access to local files by default, right?
Anyway, any help would be appreciated. Thanks.
absolute paths look like security issues to flash. use relative paths to avoid security sandbox issues.
I thought that would be a problem, so I do them all with relative paths.
I found a workaround by adding the root of the entire directory, in the exmaple case C:/.../Flash to the "always trust files from these locations" list. I still need to see if this we break if I put it online. Thanks for the input.