2 Replies Latest reply on Jun 20, 2011 1:52 PM by MuskeeterAkshay

    how to check if the event in actionscript  is initiated or not?


      Ok so I have played with event handling in action script couple of times but I have come across this situation where I need to check whether the event in the actionscript is already called or not . the code snippet looks like below:


      currentTrajectory = new ArrayCollection(event.result as Array);



      var _multiTrajectoryEvent:MultiTrajectoriesEvent;



      if ( _multiTrajectoryEvent is intialized) // this is where I need to check


      _multiTrajectoryEvent=new MultiTrajectoriesEvent(MultiTrajectoriesEvent.DRAW_AUTO_TRAJ );









      //raise an event to





      Every time I get the event result from database and I am adding result to arraycollection of event. However, I want to make sure that event object is created only if it hasn't been initialised before in order to have previous value of array collection isnide the event.


      Checking if the event object is null doesn't work and if the event is not initialized I can't check it's bubble property as well...


      I would appreciate quick thoughts for the same


      Many Thanks