TypeError: Error #1009

22 Feb

Chances are that you’ve seen this error message before. This is my number one wish for ALL the Adobe compilers - better error messages! I’ve always wondered why Flash / Flex can’t throw proper error messages and this is a brilliant example. In this case, Flash obviously knows exactly what is wrong so why not just just tell it? How about something like this:

 
TypeError: Error #1009: Cannot access the property "someprop" since it is a null object reference.
	at no.netron.tusenfryd::Map/onLoadSingle()
	at flash.events::EventDispatcher/dispatchEventFunction()
	at flash.events::EventDispatcher/dispatchEvent()
	at flash.net::URLLoader/onComplete() 
 

If I just knew the name of the object, I didn’t have to search all over for it…

22 February 2008 at 7:21 pm

5 Responses to TypeError: Error #1009

  1. avatar photo
    Keith Peters 22 February 2008 at 8:16 pm #

    amen.

  2. avatar photo
    Erik Westra 23 February 2008 at 6:13 pm #

    I don’t get it. If you are debugging using Flex builder the line with the error will be highlighted. If you are using a debug player it will give you the exact line number of the error.

    This should be enough.

    Another thing is that they (in most cases) can not give you the name of the property. In swf files all the local function properties are nameless. If you would decompile an swf your would see them named as local1 to localX.


    Greetz Erik

  3. avatar photo
    Jensa 24 February 2008 at 6:32 pm #

    Hi Erik,
    I’m not using Flex. For this project I work with designers and need movieclips and the timeline for them to do their stuff.

    But - what you say about variables being renamed is true. They should be able to solve this when you are running inside the IDE though, don’t you think?

    And really, this is just one out of hundreds. Many of them are not really informative at all. I’m sure they could have done better without putting too much effort into it.

  4. avatar photo
    Jorje Wenlinger 27 February 2008 at 12:42 am #

    cambiamos la pec de gravacion
    aprentemente isimos todos los pasos de ciempre aparece error
    1009 chek hardlock emos ejecutado hardlock pero no cambia

  5. avatar photo
    Adrian Parr 05 August 2008 at 4:47 pm #

    Hi Jensa,

    I agree completely. The error messages in Flash CS3 are technically correct, but very unreadable and user friendly. I wish they were more helpful. If they were then I’d be a lot happier about using AS3.

    Adrian

  6.