1 Reply Latest reply on Aug 30, 2006 10:57 AM by deepa subramaniam (adobe)

    Popup alert window


      I am encountering a simple but hard to me problem; simply popup an alert window, here are the codes:-

      package {

      import flash.display.Sprite;
      import mx.controls.Alert;
      public class showAlert extends Sprite {

      public function showAlert() {

      Alert.show("This is a test");


      gives runtime error as:-

      TypeError: Error #1009: Cannot access a property or method of a null object reference.
      at mx.managers:: PopUpManager$/addPopUp()
      at mx.controls::Alert$/show()
      at showAlert$iinit()

      Could anyone give me a hint to sort it out? Thanks