I am new to flex and am struggling to set a few things up.
I'm building a debugging tool in Flex that will be used in my actionscript project.
I am having trouble instantiating the tool. I've created a SWC from a flex library project, added this to the source of my actionscript project and then tried to instantiate the flex component from within my actionscript project by calling new DebuggingTool(). DebuggingTool is the name of my mxml file. When I run the actionscript project, I get this error:
[Fault] exception, information=TypeError: Error #1009: Cannot access a property or method of a null object reference.
Can anyone please let me know what I'm doing wrong here?
Thanks a lot
Try import containingFolder.DebuggingTool;
1009 is a very common error that you usually get for referencing a null entity. My guess is you are accessing a property on the DebuggingTool object before it has been instantiated.
The framework has certain rules and if you start from an AS projects, it is
very easy to violate one of those rules. Flex component parents need to be
Flex Containers in most cases.