Copy link to clipboard
Copied
I'm using
Flash CS4 with Win7 and if I create a movieclip symbol in an FLA file such class name such as GreenBox. When I put the following line into my actionscipt 3.0 code, I get the error: "You cannot debug this swf because it does not contain actionscript. The line of code is:
var greenBox:GreenBox = new GreenBox();
Any ideas what's going on. Never had these problems with CS3 and Win XP.
I did double check to see if I had the debugger version on Flash Player.
create a new directory that has no subdirectories. save your fla into that directory and give it a new name (save as..). save your document class into the same directory. retest.
if you still have the same error, copy and paste it into google and see if something works for you.
Copy link to clipboard
Copied
you probably have a document class error but there are a variety of errors that can trigger that error message. to debug, start removing /commenting out blocks of code.
Copy link to clipboard
Copied
Below is all that's in the code. If I take out the line variable declaration line, I don't get the error, if it's in I get it.
package{
import flash.display.*
import flash.events.*
public class TestFlash extends Sprite{
var greenBox:GreenBox = GreenBox()
public function TestFlash(){
}
}//end class
}//end package
Copy link to clipboard
Copied
and you have an error. use:
package{
import flash.display.*
import flash.events.*
public class TestFlash extends Sprite{
var greenBox:GreenBox = new GreenBox()
public function TestFlash(){
}
}//end class
}//end package
Copy link to clipboard
Copied
Yea, I miss typed that and forgot the "new", but even with that corrected, it still does not work.
Copy link to clipboard
Copied
do you see the same error? if yes, copy and paste the error. if no, what doesn't "work"?
Copy link to clipboard
Copied
Here's the error I get:
Copy link to clipboard
Copied
create a new directory that has no subdirectories. save your fla into that directory and give it a new name (save as..). save your document class into the same directory. retest.
if you still have the same error, copy and paste it into google and see if something works for you.
Copy link to clipboard
Copied
Putting the FLA and the AS file in the same folder worked. I've never had to do that before, but this is the first time I've used CS4 and win7.
Copy link to clipboard
Copied
sometimes weird things happen with flash. i've rarely encounterd an unexplained problem but when i do, following the above instructions usually solves the problem. i'm not sure if there are extraneous files that are being used by flash in the older directory/subdirectories, there's a cache issue or exactly what is happening.
but a solution that works for an unknown reason to solve a problem that occurs for an unknown reason is better than no solution.
Copy link to clipboard
Copied
Here's a screen shot of the GreenBox''s properties. If I remove the var line in my AS file. I don't get an error, but if I check "Export in frame 1" in the Symbol Proberties box, I get the error.