0 Replies Latest reply on Mar 4, 2010 11:34 AM by calebmei

    Validate XML and display error in non-debug version of flash player?

    calebmei

      Hi there,

       

      Has anyone try to try and catch and error, and attempt to display the error message from Error.message? It seems like error.message is only available in debug version of flash player, but not in non-debug version of flash player.

       

      What I am trying to do is to validate whether an XML is value,

         try {

           var xml:XML = new XML(value);

         }

         catch (error:Error) {

           Alert.show (error.message, "Error")

         }

       

      This works very well in debug version of flash player. Kudos to the Flash player team!

       

      In non-debug version of flash player, only the error.ID is returned.

      I can lookup the ID for the description, but error.message did indicate where the XML is invalid, and in the case of lookup error ID would not have such info.

       

      Or how do you guys usually validate XML?

       

      Much obliged if anyone has any suggestion.

       

      Cheers,

      Calebmei