Wednesday 6 February 2008

Flash ReferenceError: Error #1065: Variable Application is not defined.

If you are receiving this error when publishing your flash as3 swf it is because you need to declare your class as public. Private classes can not be used as document classes because they are out of the class package and therefore are not a part of the private scope.

I’ve seen a bunch of people with this problem so I hope this helps. (courtesy of http://optimastudios.com)

2 comments:

Simon said...

Yeah, just got bitten by this one. Got about 20-30 classes in my project. All the main ones seemed to be listed as "public", but a small minor one was missing the "public" statement and it caused an error for every single clip in my library and NOTHING would work.

Extremely frustrating!! So check ALL your classes to make sure they're public! Hope this helps someone!

Simon.

Sam McFadden said...

Thank you for this. Big help. Was converting as2 classes to as3 and didn't notice the lack of public...