1 Reply Latest reply on Dec 14, 2012 10:45 AM by Flex harUI

    Why do i need to fully qualify a reference ot flash.external.ExternalInterface....?

    TonyColby

      I have a very simple application that I'm starting with in order to understand the ExternalInterface API that is essentially the code below:

       

       

      import flash.external.ExternalInterface;

      import mx.controls.Alert;

       

      private function init():void {

       

            if (flash.external.ExternalInterface.available)

            {

       

                  lblTextFromHost.text = "External Interface Available";

        

            }

           }

       

       

      Why is it that when I fully qualify the 'flash.external.ExternalInterface.available' in the 'if' statement I don't get errors but when I just use 'ExternalInterface.available' like all of the examples I get an error saying:

       

      Error 1119:  Accessof a possibly undefined property available through a reference with static type Class.

       

      As a new-comer to Flash / Flex I'd apprecaite any guidance.

       

      Regards,

       

      Tony