Tracking Forums, Newsgroups, Maling Lists
Home Scripts Tutorials Tracker Forums
  Advanced Search
  HOME    TRACKER    Flash








Compiler Errors


I'm going through a papervision rotating cube tutorial at gotoandlearn.com, and in this block of code I'm getting 2 compiler errors
any help would be greatly appreciated. sincerely newwave
[code]
var cube:Cube = new Cube(new MaterialList({front:mm1, left:mm2, right:mm3,
top:mm4, bottom:mm5, back:mm6}),
200,200,200,10,10,10,);
scene.addChild(cube);
[/code]

[error]
Description Source
1084: Syntax error: expecting identifier before rightparen. 200,200,200,10,10,10,);
1084: Syntax error: expecting rightparen before scene. scene.addChild(cube);
[/error]




Adobe > ActionScript 3
Posted on: 01/22/2009 02:27:56 PM


View Complete Forum Thread with Replies

Sponsored Links:

[F9] Compiler Errors
This is my first time posting in this forum and have been very impressed thus far. I am experimenting with a software package developed by Flash Menu Labs. When I generated the code the following code was generated with 6 compiler errors. I am a true nubee to Flash so I do not know if I have presented a complicated issue. I appreciate any comments or advice on this project. RioMaria
----------------------------
function aso#63706
{
if (postfix != undefined)
{
aso#86691.aso#67461 = postfix;
}

{
aso#86691.aso#67461 = _root.aso#40300;
} // end else if
var loaderX = Stage.width / 2 - 45;
var loaderY = Stage.height / 2 - 10;
aso#44347 = attachMovie("loader_mc", "aso#44347", this.getNextHighestDepth(), {_x: loaderX, _y: loaderY});
aso#19970.load("data" + aso#86691.aso#67461 + ".xml");
} // End of the function
function aso#02974()
{
aso#22204 = new aso#00611(aso#86691);
setProperty("", _focusrect, false);
} // End of the function
var aso#86691 = new aso#97827();
aso#86691.aso#70116 = this;
var aso#19970 = new XML();
aso#19970.ignoreWhite = true;
var aso#44347;
var aso#16765;
var aso#57296 = new Date();
var aso#42113 = 0;
var aso#18578 = 0;
var aso#49915 = 0;
var aso#81252 = 0;
var aso#12589 = 0;
aso#16765 = false;
aso#19970.onLoad = function (success)
{
aso#16765 = true;
if (success)
{
var _loc1 = new aso#60501(aso#86691);
aso#86691.aso#44347 = aso#86691.aso#70116.aso#44347;
_loc1.aso#17736(aso#19970);
aso#02974();
var _loc3 = _loc1.aso#20941();
var _loc2 = new aso#59109(0, 0, "menu", 0, null, aso#86691);
aso#86691.aso#36545 = _loc2;
_loc2.aso#13560(_loc3, 0, null);
} // end if
};
aso#63706();
this.menuItem_mc._visible = false;
onEnterFrame = function ()
{
delete aso#57296;
aso#57296 = new Date();
var _loc1 = aso#57296.getTime() - aso#80702;
aso#80702 = aso#57296.valueOf();
if (_loc1 < 10)
{
_loc1 = 10;
} // end if
if (_loc1 > 80)
{
_loc1 = 80;
} // end if
aso#42113 = aso#18578;
aso#18578 = aso#49915;
aso#49915 = aso#81252;
aso#81252 = aso#12589;
aso#12589 = _loc1;
if (aso#42113 > 1.000000E-003 && aso#18578 > 1.000000E-003 && aso#49915 > 1.000000E-003 && aso#81252 > 1.000000E-003 && aso#12589 > 1.000000E-003)
{
_loc1 = aso#42113 + aso#18578 + aso#49915 + aso#81252 + aso#12589;
_loc1 = _loc1 / 5;
}
else
{
_loc1 = 20;
} // end else if
if (aso#16765 && aso#86691.aso#17607 > 0)
{
if (_loc1 < 10)
{
_loc1 = 10;
} // end if
if (_loc1 > 80)
{
_loc1 = 80;
} // end if
aso#86691.aso#36545.aso#07571(_loc1 / 200);
} // end if
};
var aso#22204;

View Replies !    View Related
Compiler Errors While Trying To Publish
Greetings,

I apologize if this is in the wrong section. I have a .swf file replicated with Flash CS3, but admittedly, my knowledge of AS3.0 is in its infancy and I think the problem may lye there. I would like the top, middle and bottom line days to automatically update, but they are not. Here a link the page holding the .swf file. My File. Attached is the AS 3.0 code.

When attempting to publish the file I receive these compiler errors:
**Error** Scene 1, Layer 'Layer 1', Frame 1, Line 85: 1151: A conflict exists with definition _loc1 in namespace internal.
for (var _loc1 = 0; _loc1 < _loc3; ++_loc1)

**Error** Scene 1, Layer 'Layer 1', Frame 1, Line 109: 1151: A conflict exists with definition _loc2 in namespace internal.
var _loc2;

**Error** Scene 1, Layer 'Layer 1', Frame 1, Line 112: 1151: A conflict exists with definition _loc1 in namespace internal.
var _loc1 = dateOfJan1.getDay();

**Error** Scene 1, Layer 'Layer 1', Frame 1, Line 131: 1151: A conflict exists with definition _loc3 in namespace internal.
var _loc3 = obj.elapsedDays - _loc2;

Total ActionScript Errors: 4, Reported Errors: 4

I am sure, given my newbie status to AS that I have made an error, but I cannot figure out where. Any assistance or input would be appreciated.







Attach Code

// Action script...

// [Action in Frame 1]
Stage.scaleMode = "noScale";
Stage.showMenu = false;
timeclock_class = function ()
{
var obj = this;
var day_arr = ["Su", "Mo", "Tu", "We", "Th", "Fr", "Sa"];
var month_arr = ["January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December"];
var daysInMonth = [31, 28, 31, 30, 31, 30, 31, 31, 30, 31, 30, 31];
var time_str = "";
var date_str = "";
var am_pm_str = "";
var hour_str = "";
var min_str = "";
var interval_id;
this.date = new Date();
this.isLeapYear = function ()
{
if (obj.date.getFullYear() % 4 == 0)
{
switch (true)
{
case obj.date.getMonth() < 1:
{
return (false);
break;
}
case obj.date.getMonth() > 1:
{
return (true);
break;
}
case obj.date.getMonth() == 1:
{
if (obj.date.getDate() >= 29)
{
return (true);
}
else
{
return (false);
} // end else if
break;
}
} // End of switch
} // end if
return (false);
};
this.getDaySuffix = function ()
{
var suffix = "";
var _loc1 = obj.getElapsedDays().toString();
if (_loc1.charAt(_loc1.length - 2) == "1")
{
return ("th");

}
else if (_loc1.charAt(_loc1.length - 1) == "1")
{
return ("st");

}
else if (_loc1.charAt(_loc1.length - 1) == "2")
{
return ("nd");

}
else if (_loc1.charAt(_loc1.length - 1) == "3")
{
return ("rd");

}
else
{
return ("th");
} // end else if
};
this.getElapsedDays = function ()
{
var dayOfMonth = obj.date.getDate();
var _loc3 = obj.date.getMonth();
var _loc2 = 0;
for (var _loc1 = 0; _loc1 < _loc3; ++_loc1)
{
_loc2 = _loc2 + daysInMonth[_loc1];
} // end of for
if (obj.isLeapYear() == true)
{
_loc2 = _loc2 + 1;
} // end if
_loc2 = _loc2 + dayOfMonth;
return (_loc2);
};
this.getDaysOfYear = function ()
{
if (obj.date.getFullYear() % 4 == 0)
{
return (366);
}
else
{
return (365);
} // end else if
};
this.getWeekNumber = function ()
{
var _loc2;
var week_num;
var dateOfJan1 = new Date(obj.date.getFullYear(), 0, 1);
var _loc1 = dateOfJan1.getDay();
switch (true)
{
case _loc1 == 0:
{
_loc2 = 1;
break;
}
case _loc1 == 1:
{
_loc2 = 0;
break;
}
case _loc1 > 1:
{
_loc2 = 8 - _loc1;
break;
}
} // End of switch
var _loc3 = obj.elapsedDays - _loc2;
if (_loc3 < 1)
{
week_num = 52;
}
else
{
week_num = Math.ceil(_loc3 / 7);
} // end else if
return (week_num);
};
this.update = function ()
{
obj.date = new Date();
obj.dayOfWeek = day_arr[obj.date.getDay()];
obj.elapsedDays = obj.getElapsedDays();
obj.month_str = month_arr[obj.date.getMonth()];
obj.daySuffix = obj.getDaySuffix();
obj.daysLeft = obj.getDaysOfYear() - obj.elapsedDays;
obj.weekNum = obj.getWeekNumber();
};
};
var grey_tf = new TextFormat();
grey_tf.color = 10066329;
var orange_tf = new TextFormat();
orange_tf.color = 14448640;
timeclock = new timetimeclock_class();
timeclock.update();
this.date_txt.text = timeclock.dayOfWeek;
this.date_txt.text = this.date_txt.text + timeclock.date.getDate();
this.date_txt.setTextFormat(2, 4, orange_tf);
this.month_txt.text = timeclock.month_str + " " + timeclock.date.getFullYear();
this.dayOfYear_txt.text = timeclock.elapsedDays + "" + timeclock.daySuffix + " Day | ";
var sec1 = this.dayOfYear_txt.text.length - 3;
this.dayOfYear_txt.text = this.dayOfYear_txt.text + (timeclock.daysLeft + " Days Left | ");
var sec2 = this.dayOfYear_txt.text.length - 3;
this.dayOfYear_txt.text = this.dayOfYear_txt.text + ("Week " + timeclock.weekNum);
this.dayOfYear_txt.setTextFormat(sec1, sec1 + 3, orange_tf);
this.dayOfYear_txt.setTextFormat(sec2, sec2 + 3, orange_tf);

























Edited: 03/16/2008 at 12:18:42 PM by PWC3966

View Replies !    View Related
No Compiler Errors...nothing On Stage
well i have this code as compiled class

ActionScript Code:
package{    import flash.display.Sprite;    import flash.display.StageAlign;    import flash.display.StageScaleMode;    import flash.events.Event;    public class Bouncing extends Sprite    {        private var ball:Ball;        private var vx:Number;        private var vy:Number;                        public function Bouncing();        {                        init();                        }            private function init():void            {                        stage.scaleMode = StageScaleMode.NO_SCALE;            stage.align = StageAlign.TOP_LEFT;            ball = new Ball();            ball.x = stage.stageWidth / 2;            ball.y = stage.stageHeight / 2;            vx = Math.random() * 10 - 5;            vy = Math.random() * 10 - 5;            addChild(ball);     }  }}

and this sub-class

ActionScript Code:
package{    import flash.display.Sprite;            public class Ball extends Sprite    {        public var radius:Number;        private var color:uint;                                public function Ball(radius:Number = 20, color:uint = 0xFF0000)        {                     this.radius = radius;            this.color = color;            init();               }                                    public function init():void            {                graphics.beginFill(color);                graphics.drawCircle(0, 0, radius);                graphics.endFill();                                                                                }                        }       }


I get no complier errors , but the swf is empty(background color 0x000000).
Can' t find the error which drives me crazy! Anyone experienced similar situation? (always wanted to use yoda!)

View Replies !    View Related
Application Will Not Compile, But Gives No Compiler Errors.
I am having a problem that I cannot figure out. I have searched the internet, describing as best I could and I could only find one other person with the same problem as me and no one replied to his post. Here's to hoping someone knows what is up.

My App was working fine yesterday, then I added a few lines of code to a class file. When I tried to test the movie, it wouldn't compile. It would just run through all of the frames flashing each control. It does not output anything to the Output window nor the Compiler Errors window, which is odd because even when it would compile before it would output some warnings to the compiler errors window.

So I went into the class I changed and commented out the changes I made. Still will not compile.

Also, when I try and go and Debug the movie, it tells me "You cannot debug this SWF because it contains no Actionscript". I've tried researching this problem as well, but it seems that this problem occurs when people are using the Document Class. I am not using a document class. My actionscript is on the frames.

This same problem happened for the first time on Monday, but by tinkering with files/settings, it was fixed. That is until yesterday when i made that change.

Any help would be appreciated.

View Replies !    View Related
Compiler Errors: Classpath Problems
I am working on a new project, and am getting a number of compiler errors, such as the ones below.

The class or interface 'flash.geom.Matrix' could not be loaded.
The class or interface 'flash.display.BitmapData' could not be loaded.
The class or interface 'flash.geom.Point' could not be loaded.

These errors are occurring since installing Sandy and adding a new classpath (Edit>Preferences>ActionScript>ActionScript 2.0 Settings). My classpaths are as follows.

.
$(LocalData)/Classes
C:Program FilesAdobeAdobe Flash CS3ASLibraries

Have I messed up my standard Flash classpaths, or is this likely a problem specific to Sandy? Does the order of the addresses in the classpath list matter?

Thanks for any assistance.

View Replies !    View Related
Custom Warnings Or Compiler Errors?
Is there a way for a library developer to throw warnings or compiler errors to prevent improper implementation of a class?

Wow. That's the first straightforward question I've asked you folks in a while.

View Replies !    View Related
"class SomeClass Extends Some.path.to.Class" Causes Strange Compiler & Runtime Errors
Why is it that in AS3 when you extend a class and add the fully-qualified classpath to the "extends" bit of the class body:


ActionScript Code:
class SomeClass extends some.path.to.SomeClass

I get all sorts of strange compile and runtime errors completely unrelated to it?

One example: the compiler complains about "coercing unrelated types" when I try to declare a variable that is typed to its superclass:


ActionScript Code:
var superWidget:Widget = new SuperWidget()

BUT, when if the class is declared like so:


ActionScript Code:
class SomeClass extends SomeClass

It will be fine!

It's different from AS2, huh...


Any ideas?

View Replies !    View Related
Solution To Dealing With Loader Errors (not URLLoader Errors)
Related post:
http://board.flashkit.com/board/showthread.php?t=738745

The biggest issue I have been having was when there was no custom portal icon. There would be a URL error thrown. After many google searches, I always ended up with error catching that worked with URLLoader imports. They didn't work for me.

As it turns out Loader imports (like picture and such) have a different way of posting errors:
code:
var loader:Loader = new Loader();
configureListeners(loader.contentLoaderInfo);

private function configureListeners(dispatcher:IEventDispatcher):vo id {
dispatcher.addEventListener(Event.COMPLETE, completeHandler);
dispatcher.addEventListener(HTTPStatusEvent.HTTP_S TATUS, httpStatusHandler);
dispatcher.addEventListener(Event.INIT, initHandler);
dispatcher.addEventListener(IOErrorEvent.IO_ERROR, ioErrorHandler); // the one i needed
dispatcher.addEventListener(Event.OPEN, openHandler);
dispatcher.addEventListener(ProgressEvent.PROGRESS , progressHandler);
dispatcher.addEventListener(Event.UNLOAD, unLoadHandler);
}


And with this i fixed all bugs.

Thanks to every one that helped.

View Replies !    View Related
AS Compiler
did a little search could not find anything but what is the best 3rd party action script compiler.

I don't know about anyone else but I hate the new flash mx 2004 as panel.

I really do prefer the normal mode its easier to debug.

View Replies !    View Related
2.0 Compiler
is there any compiler to use actionscript as any other programing lenguage like c++? because as ive been told is based on an other language named EWACS or something

View Replies !    View Related
SWF Compiler?
Hi All,

I'm not sure of the right terminology to use so I'll just try to explain what I need to do.

Let's say I have a bunch of swf's and they can all accept certain variables to perform certain functions within the swfs. Is there a way to allow a user to add the needed variable values and then recompile the swf or another swf containing the variables and the original swf, without using Flash?

Another way to describe it. Let's say I have a swf of a t-shirt or coffee mug image. I have this posted to the internet. How can I allow users to add their name to the t-shirt, and then save that as a single file that could be sent elsewhere or downloaded or whatever?

I know I could save the values in an external file that the swf could access, but that's not what I would like to do in this case.

Does this make sense and does anyone have a solution?

BTW the solution will need to be built in AS3.

Thanks for your help.

_t

View Replies !    View Related
Compiler For Swf's
ech...ionno if this is not a reasonable post here...but where exactly can i find just a straightforward compiler for swf's/fla's?

View Replies !    View Related
External SWF Compiler
Hi All,

Does anyone know a way to comile swfs outside of Flash on the server?

For example, say I have a swf that accepts a variable called name. But the variable comes from outside of the swf. So someone sets the variable from a web form. I then want to embed that variable value into the swf, so it will always be with the swf. My thinking was to create another swf that loads contains the first swf and also contains the new value.

Does this make sense? And does anyone know how it could be done? Additional software on the server?

Thanks.

_t

View Replies !    View Related
[CS3] Help With Compiler Error.
I'm trying a very simple transition using an MC, I have the stop(); in the first frame of my transtion MC, but somehow it doesnt stop, and I get this error;

1061: Call to a possibly undefined method gotoAndStop through a reference with static type flash.displayisplayObjectContainer.

I've attached the FLA ...

can please some-one help me with this ?

thanks..

View Replies !    View Related
On Compiler Directives
Hi,
I went through the Compiler Directives of AS 2.0 but I could not find something that would help me write something like
if (Compile under Flash Lite)
do this;
if (Compile under Flash 8)
do this;
The problem is that I don't want the compiler to complain that some Flash Lite functions (for instance fscommand2("SetSoftKeys", leftText, rightText); does not exist.
Thanks in advance.

View Replies !    View Related
.class Compiler
Sorry if this is a bit off-topic but does anyone know of a good .class compiler?

Any help would be much aprechiated. Thankyou!

View Replies !    View Related
Broken Compiler
Hey,

Alright I know its not broken.. but the thing wont recognise I've made changes to my imported actionscript files, so when I publish it, and then preview it I get results from old actionscript versions of my files. So it must be using old cache's of my file.

Right now I keep getting these trace messages that DO NOT exist in my .as file, they used to, but not anymore. This is very annoying. Its probably the reason I couldn't track this bug that popped out of no where last night.

Anyone mind explaining?

Thanks

EDIT: Nevermind. Apparently even if you overwrite some files with some other backups, and then compile the other fla, it wont use those files. It wont use any files until they have been saved to that directory - I guess flash makes a copy of them or something. So I had to make a few spaces somewhere and save the files again for flash to realize they are new.

View Replies !    View Related
Flash Compiler
I have created a series of training FLAs. The latest will not compile into a SWF. Windows generates an error referencing the a certain memory address cannot be written. The file has lots of tweens, etc. The FLA is 2MB. I uninstalled and reinstalled Flash, but that did nothing to help. Do you think I have a file, hardware or application problem? The compiler works on the other files. Thanks for any suggestions.

View Replies !    View Related
Flash Compiler
Does anyone know if any company other than Adobe has a Flash compiler in any of their software packages?
I ask because IBM is telling their Training Content customers that the SWF files that they include in the content packages for training courses they have developed under contract can only be changed/edited using IBM's proprietary "Content Producer" software.

View Replies !    View Related
Flash CS4 Compiler Bug
I just filed this bug with Adobe at http://www.adobe.com/cfusion/mmform/index.cfm?name=wishform

--
Isaac Rivera
Director of Interactive Media
Interactive One, New York


******BUG******
Concise problem statement:

Flash CS4 can't compile a class that implements an interface if the class file contains a private class.

Steps to reproduce bug:
Files for this test available at:
http://www.r1-dev.com/tests/flash-cs4-test.zip

1. Create a simple interface named 'Testable' with a single method signature 'test'.
2. Create a class that implements the interace named 'Implementation'.
3. Create a document class that implements Sprite and instantiates the implementation class named Tester.
4. Add a private class at the bottom of the file of class 'Implementation' named 'Foo'. This class does not need to do anything in particular.
5. Compile.
6. Comment the private class out and compile again.

Results:

Before commenting the private class out, the compiler throws errors indicating it can't find the implementation of the method 'test'.

After commenting the private class out, the compiler does not complain.

Expected results:

No compiler errors should be thrown before or after commenting the private class out.

View Replies !    View Related
Compiler For AS2 Scripts
Hi All,
Can anyone suggest me any javabased compilers for compiling AS2 scripts. I know asc.jar can compile AS3 scripts. Will it be able to support AS2 too? Please let me know.

Thanks in advance,
Prabakaran Srinivasan.

View Replies !    View Related
Compiler Keywords
I had a question about some compiler options in AS3. I've already googled this and I can't really find anything on it.

There are a bunch of seeming "annotations" that I'm finding as I'm exploring Flex and Flash CS3 components, of which, here are a few:
[Inspectable], [Bindable], [Event], [Embed], [Style] and a few others that I can't think of off the top of my head.
My question is what are these tags and where can I find documentation on them? My understanding is limited to the [Event] and [Embed] tags, and I'm not so sure that I understand those completely. I'm assuming the [Event] tag is strictly for ASDoc to find the types of events that can be dispatched from a class so they can be included in documentation. I know that the [Embed] tag specifies a file to be embedded in the application just as a asset can be embedded in a fla's library. So, where can I find the documentation on the others? Also, do they all apply in certain scenarios and not others? Like, is [Bindable] only applicable in Flex projects? Is there Adobe documentation available for these commands?

- TK

View Replies !    View Related
Compiler Fooling
Hey people,

I'm working in AS 2.0 all the way now, and I've ran into some problems with event handling of UI MX04 Components. Stripped down code I have:


ActionScript Code:
import mx.controls.Button;  class Foo{ ... // aButton is set during the initializing process ... private var aButton:Button;  public function aButtonClickHandler():Void{ trace("clicked"); }  private function setHandlers():Void{ aButton.addEventListener("click",aButton); aButton.click = Delegate.create(this,aButtonClickHandler); } }


Nothing wrong with the code, but the compiler gives an error stating that the property 'click' wasn't found in aButton. It doesn't let me allow my handler for the click event I just made it listen to. In this case you can get around it using onRelease, but with other events such as 'change' for a ComboBox, there is no alternative like onChange as far as I know.

When I omit the :Button strict data definition, it works. Though I do not want to do that, because I want to keep my code tidy and clean by using strict data definitions, and because I don't want to evade the problem.

The fix I found for this is to define the click method through associative array referencing: aButton["click"] = Delegate.create(this,aButtonClickHandler). This works, which proves that the code itself isn't wrong, but rather the compiler that seems to have disregarded the fact that I added a click event for the component to listen to, and therefore it should allow me to set the click event. Now I need to fool the compiler through the associative array referencing.

Can anyone confirm this ?

View Replies !    View Related
External .swf Compiler
I have written some actionscript that generates actionscript (just procedural code, not class files). I was wondering if anyone knows of an external .swf compiler?? I would like to compile many blocks of generated AS into seperate .swfs that I can then load into a running movie.

View Replies !    View Related
Bug: Compiler Error
Why bugs keep following me?

Open a new .fla, go to the first frame and put the follow code:


Code:
stop()
(this as MovieClip).play()
We know that AS can be written without semicolon (and I prefer that, since I´m a Ruby developer), but the above example, we must use semicolon after stop
This works:

Code:
stop();
(this as MovieClip).play()
It´s obviously a parse error from the compiler. This works too:

Code:
stop()
var foo = (this as MovieClip).play()

View Replies !    View Related
Compiler Instructions
Are there instructions to the compiler in AS3? For example can I ask:

#IF EXISTS mx.collections.IList
import mx.collections.IList
#ENDIF

View Replies !    View Related
Potential AS3 Compiler Bug
Would you mind trying this? At first glance, the following statement should either output "Hiya!" or throw some kind of runtime error. But it causes my Flash compiler to leave out all AS3 code when it publishes. I'd like to know if this is reproducible.


ActionScript Code:
(0?0:0)[0];trace("Hiya!");


Thanks in advance.

View Replies !    View Related
Compiler Fooling
Hey people,

I'm working in AS 2.0 all the way now, and I've ran into some problems with event handling of UI MX04 Components. Stripped down code I have:


ActionScript Code:
import mx.controls.Button;  class Foo{ ... // aButton is set during the initializing process ... private var aButton:Button;  public function aButtonClickHandler():Void{ trace("clicked"); }  private function setHandlers():Void{ aButton.addEventListener("click",aButton); aButton.click = Delegate.create(this,aButtonClickHandler); } }


Nothing wrong with the code, but the compiler gives an error stating that the property 'click' wasn't found in aButton. It doesn't let me allow my handler for the click event I just made it listen to. In this case you can get around it using onRelease, but with other events such as 'change' for a ComboBox, there is no alternative like onChange as far as I know.

When I omit the :Button strict data definition, it works. Though I do not want to do that, because I want to keep my code tidy and clean by using strict data definitions, and because I don't want to evade the problem.

The fix I found for this is to define the click method through associative array referencing: aButton["click"] = Delegate.create(this,aButtonClickHandler). This works, which proves that the code itself isn't wrong, but rather the compiler that seems to have disregarded the fact that I added a click event for the component to listen to, and therefore it should allow me to set the click event. Now I need to fool the compiler through the associative array referencing.

Can anyone confirm this ?

View Replies !    View Related
Macromedia Special Compiler?
I am very confused about the new components and the new AS2.

I tried to unzip the Button.swc supplied with FMX2K4 and used ASV4.1 to peek into the Button.swf. As expected, I see a lots of symbols and classes.

All of the classes appear with Export ID like __Packages.mx.controls.Button,
__Packages.mx.controls.UIObject
which are totally normal.

When I look into the symbol, however, this is what I see....

class mx.skins.Border extends mx.core.UIObject
{
function Border () {
super();
}
function init(Void) {
super.init();
}
static var symbolName = "Border";
static var symbolOwner = mx.skins.Border;
var className = "Border";
var tagBorder = 0;
var idNames = new Array ("border_mc");
}

It looks almost exactly like the Border.as in the class folder!

Well, so ar nothing special.... but what I did after this was open the StandardComponent.fla supplied by Macromedia, to the the library and Export the Button component as swc.

I unzip the .swc I just created, decompile it with ASV4.1.... it looks almost the same at first, but when I look into the SAME class, this is when I got........

#initclip
if (!_global.mx) {
_global.mx = new Object ();
}
if (!_global.mx.skins) {
_global.mx.skins = new Object ();
}
if (!_global.mx.skins.Border) {
var _local1 = function () {
super();
};
mx.skins.Border = _local1;
var _local2 = new mx.core.UIObject();
mx.skins.Border.prototype = _local2;
_local2.init = function (Void) {
super.init();
};
_local1.symbolName = "Border";
_local1.symbolOwner = mx.skins.Border;
_local2.className = "Border";
_local2.tagBorder = 0;
_local2.idNames = new Array ("border_mc");
(ASSetPropFlags(mx.skins.Border.prototype, null, 1));// not popped
}
#endinitclip

Same symbol, same component, same class, but my own Flash makes something completely different from what Macromedia does...

How can I get my component compiled the way Macromedia does???

View Replies !    View Related
Compiler, .fla And .swf File Sizes
Hi!
I have this situation with 2 files, all run-time actionscript, accomplishing the same thing but in slightly different ways with these file sizes.

a.fla 112 kb ---> a.swf 23 kb
b.fla 64 kb ---> b.swf 23 kb


Then I have 2 other files, all run-time actionscript, accomplishing the same thing but in slightly different ways with these file sizes.

c.fla 98 kb ---> c.swf 20kb
d.fla 96 kb ---> d.swf 4kb

WHAT IS THE COMPILER DOING? Does the compiler build in efficiencies? Is the goal to shoot for a smaller .swf or is a smaller .swf not necessarily more efficient code? What are the tradeoffs?

Any insight or redirects greatly appreciated.

Thanks much

View Replies !    View Related
Flash Compiler & Decompiler Help
Hi there, I accedentily deleted my .fla file for my project and I cant get it back. So I was wondering how I use this flash compiler and decompiler program?

If there is an easier way of making it so I can edit the .swf file then please tell!

Thanks heaps.

View Replies !    View Related
SWF To FLA Compiler Or Positioning SWF Over SWF With DIVs
Hello,

I have to make some minor adjustments to a very old Flash site I don't have the FLAs from anymore.

I'm wondering if it's possible to place a SWF movie over another SWF movie, so that I don't have to edit the old SWFs.

I've been looking at some SWF to FLA decompilers, but I haven't been able to test a single one of them, since all of them are demo's with restrictions which basically tell me nothing of what I can expect from them when I buy them.

Does anyone know of a free SWF to FLA decompiler that actually works and leaves the actionscript etc intact?

Your help is greatly appreciated!

View Replies !    View Related
Free Flash AS3 Compiler?
I'm looking for a free or affordable flash AS3 compiler. I am trying to find either find an AS3 command line compiler that i can then run through a python script via a server side language like asp .net or a server side compiler of some sort.

Either way im tring to find a compiler that can compile a movie using as3 code using any language and i will worry about getting it to work via server side.

It needs to be in AS3 and i don't want to use the flex sdk. I have found a couple like haxe(haxe.org) although it requires not a direct compile and a tad modification to the code.

Does anyone know of any solutions? I

View Replies !    View Related
Compiler : Syntax Error
Uhhmmmm now dont understand this : or i do, just what syntax????

Code i am using

Code:
InstanceName_0.eingabe_txt.html = true;
first_btn.onPress = firstPage;
function firstPage() {
InstanceName_0.eingabe_txt.htmlText = "<font size="+1"><b><p>Plan du site: [much more text here]";
}
With that code, what punctiation am i allowed? And how do i put the ones i cant?

Please help meh

View Replies !    View Related
Does The Compiler Cache Actionscript?
Is it possible that the flash compiler is caching my actionscript? I compile my movie to watch my traces and everything is great. I comment out the trace actions and compile again but the traces are still present? It looks like my compiler is caching my actionscript. Has anyone seen this before? I'm at a loss as it seems quite abitrary when it decides to use a 5 minute old version of my classes or the latest.

View Replies !    View Related
Stand-alone ActionScript 3.0 Compiler?
I'm very new to this ActionScript/Flex thing, but I'm a command line type of guy from way back, and the Flex 2 SDK thing being made free drew my attention.

Anyway, it appears that MXML/ActionScript is akin to HTML/JavaScript. Is that true? Can you write stand-alone ActionScript files, which dynamically create the MXML objects on the fly and compile them without writing one line of XML code?

Thanks in advance, and if I asked a dumb question, be gentle

View Replies !    View Related
False Compiler Error Bug
pretty sure this is a bug in the compiler but i just wondered if anyone knows of it.

It's coming up with '1046: Type was not found or was not a compile-time constant: scroller.' and '1180: Call to a possibly undefined method scroller.'

There is no call or any mention of 'scroller' in this script. The lines it is pointing too are unrelated, in fact one is a blank line with no code whatsoever. If i add some extra blank lines at the beginning the lines in the error dont change so it cant be anything to do with the code.

Any clues on how to solve this?

View Replies !    View Related
Compiler Error 1046
Hi All,
I am sure just by the title of this that you will know that I am new to this. I can bet that this is a simple fix but for the life of me cannot figure it out. I am getting an error 1046 on the 3rd line and an error 1180 on the 7th, please help me
s_btn.addEventListener(MouseEvent.CLICK, goSer);
function goSer (e:MouseEvent):void {
var newSer:ServPage = new ServPage();
this.addChild(newSer);
newSer.x = -1.0;
newSer.y = 198.0;
}

View Replies !    View Related
.fla Command Line Compiler
Hi,
I'm very new to flash and action script. Is there a command line compiler that will let me compile action script 2?
Any info will be much appreciated.

Thank You

View Replies !    View Related
Flash CS4 Compiler Problem
Hello all, I' just installed CS4 and I find that although flash swf's run nicely, no code is apparently is running. In fact, when I click the "verify code button" nothing happens. If I press the automatic Ident there is a message saying there are errors in the errors panel, but in fact nothing appears there. I can't make a simple trace show up!

Any thougts?

View Replies !    View Related
Newbie Getting A Compiler Error
Hi,

I'm very new to Flash. I get a compiler error when I try to do the Animation example in the Help file. (Found here http://livedocs.adobe.com/flash/9.0/main/wwhelp/wwhimpl/common/html/wwhelp.htm?context=LiveDocs_Parts&file=00000026.html).

Here's the ActionScript in my frame 1 (copy and pasted from the tutorial).:

stop();


function startMovie(event:MouseEvent):void
{
this.play();
}
playButton.addEventListener(MouseEvent.CLICK, startMovie);


function gotoAuthorPage(event:MouseEvent):void
{
var targetURL:URLRequest = new URLRequest("

View Replies !    View Related
.fla Command Line Compiler
Hello,
Does anybody have a command line compiler for action script 2 that will use the .fla file.

View Replies !    View Related
Workaround For Bug In Adobe Compiler?
I have found a bizarre bug in Flash CS3 wherein certain unicode characters cannot be put in a string literal!

for example:

public static const ct_words : Array = [
"uC0ACuACFC", // tthis is okay, in korean
"alpha",
"u679C", /// this gets a compiler error, is chinese
"foobar" ];


the code "u679C" generates a compiler error in CS3 for no good reason,it is just another unicode character!

edj

View Replies !    View Related
This Code Breaks The Compiler
I am using Adobe Flash CS3 Professional Version 9.0 and there are no new Updates available via the Help menu.

I perform the following.

Create a new Actionscript 3 fla.
Press F9 to open the Actions frame
Paste in the code below.

trace("here 1");
var mc : MovieClip;
trace("here 2");
if (false) {
if (mc == null) {
}
}
trace("here 3");

Press Ctrl Enter to launch the swf.

None of the trace statements appear.
This is because the compiler crashes when trying to compile the code.

Turn on "Generate size report" to see the size of the ActionScript Bytes.

ActionScript Bytes Location
------------------ --------
17 ActionScript 3.0 Classes

Now, comment the nested if statement in the code:
// if (mc == null) {
// }

Press Ctrl Enter to launch.
The trace statements appear.

and the "Generate size report" displays:

ActionScript Bytes Location
------------------ --------
355 ActionScript 3.0 Classes


As you can see, the compiler did not generate the ActionScript byte code in the first compile as only 17 bytes were generated.

I'm thinking this is a compiler bug.

I mean, what else could it be?

View Replies !    View Related
FLV Player Compiler Error
Hi all

I created my own FLV player skin and then wanted to know how to pass variables to flash via HTML so I could make my progressive download FLV player dynamic. I found a helpful tutorial on passing variables and just tried this tutorial out. I am using Flash CS3 and I am fairly new to Flash.

When I get to the stage in the tutorial below of publishing to HTML I get the following Actionscript 3 compiler error. Its so frustrating as I am slow close to getting this sorted and I am not sure what I am doing wrong.

Error message:
1120: Access of undefined property video.
1119: Access of possibly undefined property contentPath through a reference with static type fl.video:FLVPlayback.

Actionscript code:
stop();
var passed:String = video;
player.contentPath= video;


I am using the instance name of 'player'. I just wondered is it because the actionscript refers to 'contentpath' which is now 'source' in CS3? Although changed 'contentpath' to 'source' and still had a similar problem.

This is the link to the tutorial I am using:

http://www.webdesign.org/web/flash-&-swish/flash-tutorials/passing-variables.12759.html

If anyone can help I would be very grateful

Many thanks

Rob

View Replies !    View Related
Strange Compiler Error
I have Flash CS3. I am using ActionScript 3.0. My program used to work fine. Now SOMETIMES, without any modification to the program, I get the following compiler errors:

For the following instruction: import com.flashsupport.video.Playlist;
I get the following compiled error: 1172: Definition com.flashsupport.video:Playlist could not be found.

For the following instruction: import com.flashsupport.video.BackgroundBox
I get the following compiled error: 1172: Definition com.flashsupport.video:BackgroundBox could not be found.

For the following instruction: import com.flashsupport.video.Thumbnail;
I get the following compiled error: 1172: Definition com.flashsupport.video:Thumbnail could not be found.

Again I want to point the fact that this program used to work fine. No modification was done to it.

Anybody had this kind of problem?

View Replies !    View Related
MTASK COMPILER (actionscript 2) ?
I installed the zipped file "mtask.zip" for Actionscript 2... unzipped the zipped file... and then... well... dont know. I'm puzzled about what else to do to make it work

I've read about the compiler, but nothing has really given that much disclosure on how to make it work.

I've got two fat Text books that are dying to be discovered, but I am restricted in discovering them without the Actionscript 2.

Well I hope what I have said is not too confussing, but thanks for reading my post anyway. Reply, reply, reply... dont be shy:-)


en Iesous, Hagios

View Replies !    View Related
Apollo Compiler And Mx: Classes
Hello,
I have succesfully compiled and packaged the "hello World" Apollo application from the command line, but when i try to compile an mxml with AS code which import any class ("import mx.containers.Panel", in this case), the compiler fails with a strange error message, mix of french and english (the operative system language is French) which seems to be the equivalent to:

(1061)Call to a possibly undefined method _ through a reference with static type _.

it happens also with the rest of samples, never find the path to "mx" or "com.adobe" classes.
-how can I set the compiler so it find those classes? I don't find any mxmlc option or tag in apollo-config.xml to configure the path to these classes.
any clue or aditional instruction about the compiler configuration would be really appreciated,
Guillermo.
(Apollo SDK on frenchie winXP)

View Replies !    View Related
Fl Package And MXMLC Compiler (Sen)
Hey guys,

I'm trying to use fl.transitions.Tween using the MXMLC compiler that comes with the Flex SDK 2, and it boots an error at me because the fl package doesn't come included with the SDK. I could move over and use mx.effects.Tween, but I was hoping I could ensure compatibility with the Flash IDE by using fl.transitions.Tween. Is there any way I can access the fl package using the Flex SDK?

View Replies !    View Related
Mxmlc Compiler Trouble
I've been working with mxmlc for the past couple of weeks, and I've hit a roadblock. Any time that I specify the package definition, like this,

ActionScript Code:
package some.arbitrary.definition {...}

mxmlc throws an error:

Quote:




Error: A file found in a source-path must have the same package structure '', as the definition's package, 'some.arbitrary.definition'.




I get the premise of this error: my class needs to be in a folder at ./some/arbitrary/definition. But no matter what directory structure I use, I can't get mxmlc to compile the file.

What exactly do I need to do to get mxmlc to behave? Is there a configuration variable that deals with this?

Senocular?

View Replies !    View Related
My Compiler Wont Work....
In the actions pannel, you can assign a variable an HTML string.

As long as you keep in it "" you can do just about everything

{ right now I have : urls = "<html><body> stuff </body></html>" }

and it works well enough as HTML output.

What I'm worried about is 1: what a pain that will be to update 2: if I change that movie every time I update, will people have to keep reloading it?

So.. I made a sweet PHP news log in / post system (that way I can also give admin to other users) and it will update in the movie.

So if I can get my news movie to load a frame that really just a generated HTML doc, and load it, I would be very happy.

I tried <?php include("news.php"); ?> (I put it in HTML doc tags like I do for my other pages, and hoped my server would compile it like my real PHP driven site)

But it gives me an output worning... and then doesn't display anything.. if someone could tell me how to load a frame from inside a movie, I could load the nwes page in the window and it would be like a normal browser, so it should compile...

If someone know how to solve this little problem, please help.

View Replies !    View Related
Copyright © 2005-08 www.BigResource.com, All rights reserved