3 Replies Latest reply on Sep 24, 2010 12:15 PM by Ned Murphy

    Compiling errors


      A vendor supplied us with a simple stand alone source .fla file (no actionscript files, etc.)  that doesn't compile as there are four errors that says "The class or interface xxx could not be loaded for the following classes:


      • flash.display.Sprite;
      • flash.text.TextField;
      • text.TextFieldType;
      • printing.PrintJobOrientation;


      At first I thought they hadn't supplied us with some external actionscript files but in looking at the file, it's set to publish to Flash 10 / Actionscript 2.0 and in looking into these classes, they seem to be Actionscript 3.0 ONLY??


      They say they're on CS4 (same as me) and it compiles fine and I get an unusable file.


      I commented out the imports for these classes and the file works fine thinking they can't be used anyways in Actionscript 2 and it works but they insist it compiles fine on their end.


      I tried it on another computer thinking that an install might not have all the classes, etc., but the same issue.


      I'm not an Actionscript expert by anymeans, but does it make sense what they're saying?  Any obvious misses on my part?


      Link to source file : http://www.kamunga.com/org.zip/

        • 1. Re: Compiling errors
          Ned Murphy Adobe Community Professional & MVP

          Try setting the publish settings to AS3 and see if that works okay for you.

          • 2. Re: Compiling errors
            trev_c Level 1



            Yes I had but that just gives other errors/warnings and the file is then unusable.




            1086: Syntax error:expecting semicolon before minus.   var bg_img:background-img;


            WARNING: Actions on button or MovieClip instances are not supported in ActionScript 3.0. All scripts on object instances will be ignored.


            I'm pretty certain it's an actionscript 2 file and just looking for confirmation that they are in fact Actionscript 3 ONLY classes that wouldn't compile under actionscript 2 so I can somehow prove to the vendor that they're 'misinforming' me...



            The above link had an extra /  on it, should be:


            Link to source file : http://www.kamunga.com/org.zip

            • 3. Re: Compiling errors
              Ned Murphy Adobe Community Professional & MVP

              The Sprite class came into being with AS3, so it doesn't belong getting imported into an AS2 file.  While the TextField class exists in AS2, to invoke it does not require importing the class in an AS2 standalone file.  So you are probably correct in saying those lines don't belong in the file, which I think you say you proved by removing them and getting things to work properly.


              As far as trying to prove to a vendor that they are wrong... that's usually not a worthwhile endeavor regardless of the obvious.  I don't remember ever dealing with any company that will admit it made a mistake.