开发者

Flash CS5 won't execute AS3 code

I am getting a strange issue in Flash CS5. I have a .fla file that was working fine up until recently. Now, when I Ctrl-Enter to Test Movie...nothing happens.

I h开发者_开发知识库ave a Document Class set up (and when I click the pencil button, it opens up the right script, so Flash knows where the code is) called Main. In the constructor, there is a trace('Main()') just so I know the constructor got called, but that trace isn't showing up. A few days ago this same code was working fine, so i'm guessing I knocked around a setting or two in the IDE (not sure which, since Flash has the classpath set correctly)

Thanks in Advance,

-Esa

EDIT: Here's a worrying line from the Size report...Why is Actionscript Bytes '0'?

Scene      Shape Bytes    Text Bytes    ActionScript Bytes  
-------    -----------    ----------    ------------------  
Scene 1              0             0                     0

EDIT 2: I also added a trace to the timeline, and that still doesn't show up (and ActionScript Bytes is still 0...the swf size hasn't actually changed even though I added the code).

Also I have restarted the program several times, and even restarted my computer (and did the 'Delete ASO' thing that Mattias suggested). No dice.


Try copying only the files you need (.as, .fla) into a different folder and recompile. If a big project has too many files within the main directory I think it just gets tired midway while compiling


Seems like Flash lost the connection to the document class.

First try to remove the cache:

  1. Control -> Delete ASO
  2. Hit Ctrl-Enter

If it still does not work:

  1. Remove the document class and hit Ctrl-Enter.
  2. Add the document class again and give it a new try.

If it still does not work, try changing to an other Document Class to see if that works.

Hope this helps.


Are you sure the FLA is set to AS3 (and not AS2) ?

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜