Compilation :: Flash Compile Error?
Dec 19, 2009i am creating a web site and when i compiled my flash code so it writing that
TypeError: Error #1009: Cannot access
a property or method of a null object
reference. at
[code]....
i am creating a web site and when i compiled my flash code so it writing that
TypeError: Error #1009: Cannot access
a property or method of a null object
reference. at
[code]....
I moved from using the Flex Builder 3 IDE to Flash Builder a couple weeks ago and have noticed a ridiculous jump in compile times with the same project. It almost seems like every time I build it does a clean build. The project I am working with is pretty big, but when it takes more than 4 mins to build, something is wrong. I tried adding more memory to eclipse and all the tricks I could find on the web but the compile time never really changed. I am running under Windows 7 32bit, and I get the same performance from the plugin and stand alone version of the IDE.
View 2 RepliesI'm using Flash Develop to build an as3 application using the Flex compiler. In the constructor of a particular class I have written the following code
Code:
//constructor
public function Test(par1:int, arr:/*int*/Array = [1, 2]){ <----- compiler shows error here
[code].....
I just upgraded to CS4 and now I can't compile my project. First of all I get a random error like this 1087: Syntax error: extra characters found after end of program. on(press){} The location of the error (file, frame, line) is totally random, pointing to frame that has nothing in it or a frame with a simple stop(); command, etc My other error is a run time one that appears after the compilation The following JavaScript error(s) occurred: SyntaxError: unterminated string literal All that code was working fine yesterday with CS3, any idea why CS4 wouldn't handle it the same way?
View 4 RepliesI'm having an odd problem that isn't mission critical since I can use the command line with no probs.In my earlier post http:[url]... I had problems getting the web compiler to work.Now that it's working I use this in a browser to compile: http:[url]...
and I get this error as a result:
ERROR : Could not resolve to a component implementation.
349 <mx:filters>
350 <mx:DropShadowFilter alpha=".25" angle="90" />
351 </mx:filters>
Everything is legit and the most recommended solution is that the namespaces aren't correct. I've checked those and they're fine. Other answers I've come across relate to external components causing a problem but as you can see, I'm not using an external component.Here's the kicker. If I do a compile via command line:
mxmlc topsight.mxml
it compiles perfectly.Specs are still the same from the prior post and I'm using the Flex 3 SDK.Not sure if this would help but I did the download from http:[url]... and I clicked on the Open Source Flex SDK - Milestone 3.3
I keep getting this error message when going to Live Data or previewing in browser:
Microsoft JScript compilation error '800a03ec'
Expected ';'
/newdb/[name of asp file executed].asp, line 4
Dim rFauna__MMColParam
----^
[code]....
I have a movie clip called turret that is on the screen and is instanced as Turret, I have a movie clip called bullet and that is in the library exported for AS "bullet" no quotes. Here is the website [URL] My frame (main) class is called du34
[Code]....
I have a problem and I don't know where to start debugging it.I have some buttons with rollovers and I'm using strings to try and automate localization.All the buttons have two frame with the same text in each frame, but with a different color applied. I use the same ID for each frame as the translations will be the same.When I compile the movie I get this error
butIntroHow, Line 151086: Syntax error: expecting semicolon before rightparen.
from the button. I haven't any action script attached to the button, so I presume at compile time some code is added to deal with localization.
I'm getting this error when compiling a newly created application with SDK 4.1:1017: The definition of base class Application was not found.I can click on the SDK library path in the Flash Builder Explorer and navigate to the spark->components->Application object.
View 1 RepliesI was looking at a game engine code and I tried to reproduce myself but I got a compile error.Main.as
package {
import flash.display.Sprite;
public class Main extends Sprite
[code].....
Word to the Flash Genies-- Heres my wish that hopefully someone else is struggling with an enormously mind-boggling bug in flash cs3-- when I try to create a public class that extends any of the native flash display objects, and I put this in its own package, even after specifically importing the specific class OR the package wildcard .* the fla that I'm compiling returns error 1017-- Base Class Definition not found. The fla is set to the correct classpath. This situation slipped from 'minor annoyance' to 'mind boggling' after I moved the directory to a different pc with cs3, reset the local classpath and it compiled perfectly. So then I moved the directory to a mac, running flex builder, and made a tester file to use the class, which compiled perfectly.
For some wierd reason, this particular computer cannot compile, even though nothing had changed in the actual class. Maybe it is important to note that this machine is running Vista (and perhaps should not be!)? Maybe it is important to note that the package is part of an SVN directory? Maybe it is important to note that after re-saving the same class file, changing only the class name (from BitmapSprite to BSprite) enabled it to compile on this machine, even though both the mac and other pc (running windows XP) could compile the class as BitmapSprite. I'm not sure if the name change or just re-saving allowed it to compile--but maybe it's significant that the new named instance was not committed to svn.
I seem to have a problem here with my AS3 code.Im just trying out AS3 for pratically the first time and I keep runing into errors. Usually I tinker about and seem to resolve them, but this one stumps me, since it "should" work.
package {
import flash.display.*;
import flash.events.*;
[code].....
So, I'm making a game and when I test my class into a file I get four errors of the same type '1046: Type was not found or was not a compile-time constant: Stage and TextField'.
[Code]...
There is probably no way for this but does anyone know a method of excluding certain functions from a build by use of a meta tag and or compiler option?I want to expose some functions for testing but not have them bloat the application on production. I could create separate testing classes and test for a complier directive or option and only load them if necessary but I like the idea of having the test function on the actual object (in the class).
View 2 RepliesJust tried compiling a iOS app I developed in Flash 5 using Flash 5.5. Getting a bunch of errors related to TCM. Here's a sampling of the errors:
[Code]...
I am trying to load a file into flash cs4 that was created in flash cs3. The file is from a site that explains how to make a slideshow. When I load it I get all sorts of errors. I tried other files and got the same problem. One error said that the variable arguments were wrong
View 1 RepliesI have three movieclips, imported as part of a FLA file from inDesign. There are 3 frames in the movie labeled, page_one, page_two, and page_three There is one movieclip on each frame labeled as follows:
page_one had movieclip spread_one
page_two had movieclip spread_two
page_three had movieclip spread_three
there is actionscript on each frame:
on frame 1, (label page_one):stop();
spread_one.addEventListener(MouseEvent.CLICK, moveme1);function moveme1(e:MouseEvent):void{ gotoAndStop("page_two"); }
on frame 2 (label page_two):
stop();
spread_two.addEventListener(MouseEvent.CLICK, moveme2); function moveme2(e:MouseEvent):void{ gotoAndStop("page_three"); }
on frame 3 (label page_three):
stop();
spread_three.addEventListener(MouseEvent.CLICK, moveme3); function moveme3(e:MouseEvent):void{ gotoAndStop("page_one"); }
when I compile in flash, it works.when I compile in air 2.6 I get this error after I click on frame 3 (page_three), in spread_three:
TypeError: Error #1009: Cannot access a property or method of a null object reference. at objecthood_fla::MainTimeline/frame1()[objecthood_fla.MainTimeline::fr ame1:5] at flash.display::MovieClip/gotoAndStop() at objecthood_fla::MainTimeline/moveme3()[objecthood_fla.MainTimeline::f rame3:8]
[code]....
I created another 3 page test spread in inDesign, with only a rectangle on each page and exported as FLA.I used the same code as above and it compiled fine in both air and flash.
I have a project with 430+ as3 classes, which we have been developing for a year.
For about a month now, sometimes the FLA won't compile, and no error or warning will be displayed. When I publish the movie, it takes about 60 seconds to compile, but when it's finished, the swf file produced it's only 1,1KB (instead of 850k which should normally be) and I get absolutely no Compiler Error or warning.
Sometimes, if I delete the ASO files and recompile, it works fine. Other times, this won't do it and I would have to quit Flash and open the project again. I have "Compress movie" and "Reduce file size and increase performance" set to false for nearly 2 months now, because I read somewhere that Flash can have trouble with projects using hundreds of classes (this actually helped).
Last week however, I cannot get it to work. No matter what I do, it won't compile. I try to delete a whole bunch of code from the Main class, get it to compile fine and then add a few lines each time, only to see that any random line of code can make it stop compiling again.
I'm creating on Flash CS5 an animation of navigation buttons. On AS3 I have this code:
[Code]....
When compiling there are 3 error messages which say the same: "Error 1046: Type wasn't found or was not a compile-time constant: MouseEvent." (Look out, it refers to those where are written on the 'function' part. Not to the 'addEventListener' ones)
I tried out with AS2.0 but it's impossible to be read. Now in the first line you can read "stop();", this is an instruction to stop the animation (slide) of the navigation buttons once appeared on Stage. My teacher has the same code (and the same version of Flash CS5 as mine) and it can run with no problems. Supposedly this is a basic code which can be compiled very well. This is not my case, though. Is there something wrong with my code? Do I have write on more specific codes to be run?
My Flex project has six sub-projects. How can I speed up compilation?
View 1 RepliesI started a project in Flash CS4 using Actionscript 3.0 and targeting Flash Player 10. Later, I was told it had to target FP9, so I knocked it down, and then started receiving this error:
1046: Type was not found or was not a compile-time constant: Vector.
I have an actionscript file with a class defined, and I am trying to define an object for that class in another actionscript file but I keep getting a compile error that says type not found.[code]
View 5 RepliesIs there a simple way to report the time necessary to compile an applcation in Flash Builder (in the Console or an external file) ?
I want to compare the average compilation time between the usual Flex compiler and HFCD (HellFire Compiler Daemon) for a given project.
how can I do the following in a Flex project?[code]then flash builder gives me a compile error:1018: Duplicate class definition: Main
View 2 RepliesI am working on a AS3 file called Main using Flash CS3.When testing the movieclip, the compiler showed an error on the line:import flash.display.MovieClip;The exact message is this:1046: Type was not found or was not a compile-time constant: TextField.import flash.display.MovieClip;The code I used is rather short. It is shown below:
ActionScript Code:
package
{
[code].......
I'm using Flash Pro CS5. My FLA file's code says
#include "myasfile.as"
myasfile.as holds my code, and starts with "@estr = function ()" When I go to export movie, I get "myasfile.as, Line 1 unexpected '@' encountered" Why do I get this message?
I have a character added as Child in the Main Time line and i am trying to make a class for that same char to control it, but as soon as i start it gives me this huge annoying error that says It has a compile time-constant error in the
private function checkKeysDown(event:KeyboardEvent):void{
Full class code below
Code:
[code]....
This is my first time using flex. I tried compiling thecripts below usingmxmlc example.mxmlAnd I get:Error: Type was not found or was not a compile-time constant:UIMovieClipThis is on a windows machine. If I type just "mxmlc" I getthat I'm using version 3.1
View 17 RepliesI have a symbol with name and class name "cat". I also have buttons with names and classnames of values "upButton" "downButton". I dragged the symbols onto the stage and gave them instance names of "cat", "upButton", and "downButton", and tried to control the position of the cat using the buttons, however I got the error message:
"type was not found or was not a compile-time constant"
So I tried changing the name of the instances to cat2, upButton2, and downButton2, and it works perfectly fine. So am I not allowed to have instance names identical to the class name? This is strange because in the book I am working out of, the instance names are identical to the class names.
I am trying to create a a menu (eventually on two rows of three buttons) Here is code so far:
the pages are on timeline at 10, 11 12 ( 13 14 15.)
Code: Select all
stop();
var menu_label:Array = new Array("Homepage","Projects","About us");
var total:Number = menu_label.length;
[Code].....