You'll have to register a handler for the
initialize
event of the
Application
class. That'll be the first event you can handle, as the
Application
instance is the first object created in a Flex application. More information can be found
here[
^] (and of course in Google)