View Full Version : Custom classes with Imports = 1046: Non-CTC:SimpleButton

12-21-2007, 01:14 AM
Ok, so why (in Flash IDE - AIR 1.b3) do I keep getting :

1046: Type was not found or was not a compile-time constant: SimpleButton.

for everything (on each import, the class declairation and the constructor method declairation) in a simple class like :

Edit: the Class didn't really matter. It was because I had a button within the clip I was trying to apply a custom class upon. Which makes use of the SimpleButton class. I had tried to import that into my class just to make sure but that had no effect. The only way I finally got it stop throwing that error is by setting those buttons to "export to actionscript" or I could have just made a custom button.... man that was driving me (more) nuts. Maybe it's always like this now that I think about it (lol). I hardly ever use the built in buttons in Flash.

02-11-2008, 01:15 AM
DUDE! thanks! I was going nuts also.
Thanks for the edit.

04-26-2008, 11:33 PM
The story behind the problem: cs3 ActionScript in many ways enforces objective representation of everything and class library structure. Buttons must be imported into the main movie with an "import flash.display.SimpleButton" command, or a more broad-based "import flash.display.*".