Error 1136 When Creating Class.
It seems like it would be a pretty simple error to fix, but I have been looking around for hours and haven't found anything...
There's a Main.as file calling an external file, PerpetratorMaker.as which creates a new Perpetrator object, which is a movie clip I drew which is exported for actionscipt in the .fla file's library.
here is the code:
PHP Code:
package {
import flash.display.MovieClip;
public class PerpetratorMaker extends MovieClip { public var willbeshot:Perpetrator = new Perpetrator; public function PerpetratorMaker () { //Do stuff } } }
The exact error I get is this:
Code: 1136: Incorrect number of arguments. Expected 1. Any ideas?
FlashKit > Flash Help > Actionscript 3.0
Posted on: 02-24-2008, 09:50 PM
View Complete Forum Thread with Replies
See Related Forum Messages: Follow the Links Below to View Complete Thread
Error 1136: Incorrect Number Of Arguments.
Gosh, I'm getting that freaking Error 1136: Incorrect number of arguments. Expected 1. Source = setLoginFields();
But I dont see why and how I can add an argument... All I'm doing here is setting shapes and textfields... You guys have an idea?
Code:
package {
import flash.display.*;
import flash.filters.DropShadowFilter;
import flash.text.TextField;
public class CartTest extends MovieClip {
private var Login:Sprite;
private var LoggedIn:Sprite;
private var Register:Sprite;
private var r1:Sprite;
private var r2:Sprite;
private var r3:Sprite;
private var bg:MovieClip;
private var ombre:DropShadowFilter;
private var Cart:Sprite;
private var _mask:MovieClip;
private var _register:MovieClip;
public function CartTest() {
drawCartPanel();
drawClientPanel();
setLoginFields();
}
private function drawClientPanel():void {
drawLogin();
drawLoggedIn();
drawRegister();
drawBackground();
bg.addChild(Login);
bg.addChild(Cart);
bg.x = 30;
bg.y = 50;
}
private function drawLogin() {
Login = new Sprite();
Login.graphics.beginFill(0xffffff);
Login.graphics.drawRect(10,90, 470, 300);
Login.graphics.endFill();
addChild(Login);
}
private function drawLoggedIn() {
LoggedIn = new Sprite();
addChild(LoggedIn);
}
private function drawRegister() {
Register = new Sprite();
addChild(LoggedIn);
}
private function drawBackground() {
bg = new MovieClip();
bg.graphics.beginFill(0xcccccc);
bg.graphics.drawRect(0, 0, 970, 400);
bg.graphics.endFill();
addChild(bg);
var dropShadow:DropShadowFilter = new DropShadowFilter();
dropShadow.color = 0x000000;
dropShadow.blurX = 10;
dropShadow.blurY = 10;
dropShadow.angle = 45;
dropShadow.alpha = 0.6;
dropShadow.distance = 10;
var filtersArray:Array = new Array(dropShadow);
bg.filters = filtersArray;
}
private function drawCartPanel():void {
Cart = new Sprite();
Cart.graphics.beginFill(0xffffff);
Cart.graphics.drawRect(490, 90, 470, 300);
Cart.graphics.endFill();
addChild(Cart);
}
private function setLoginFields(e):void {
var email:TextField;
var pwd:TextField;
var email_txt:TextField = new TextField();
var pwd_txt:TextField = new TextField();
email_txt.text = "email:";
pwd_txt.text = "password";
Login.addChild(email);
Login.addChild(pwd);
Login.addChild(email_txt);
Login.addChild(pwd_txt);
}
}
}
Click To Pick Up, Click To Drop - Error 1136
trying to get the click to pick up & click to drop function working...
getting this error...
"1136: Incorrect number of arguments. Expected 1."
ActionScript Code:
package {
import flash.display.Sprite;
import flash.display.MovieClip;
import flash.text.TextField;
import flash.events.*;
import flash.display.DisplayObject;
import flash.ui.Mouse;
import flash.display.BlendMode;
public class connectWars extends Sprite {
private var gameState = 2;
private var startX = 0;
private var startY = 0;
private var clicked:Boolean = false;
public function connectWars() {
createGrid();
// Call Game Loop
stage.addEventListener(Event.ENTER_FRAME, gameLoop);
}
public function gameLoop(enterFrame) {
switch (gameState) {
case 1 :
//initIntro();
break;
// Choose Player
case 2 :
choosePlayer();
break;
//player 1
case 3 :
//player 2
case 4 :
greyOutBoxes();
pickUp();
break;
case 5 :
//initGameOver();
break;
default :
trace("THE GAME IS BROKEN");
break;
}
}
// choose which player goes first (random)
function choosePlayer(){
gameState = Math.ceil(Math.random() *2+2);
}
// cover the oppenants cards
function greyOutBoxes() {
if (gameState == 3) {
redCardCover.alpha = 0;
blueCardCover.alpha = 1;
} else {
redCardCover.alpha = 1;
blueCardCover.alpha = 0;
}
}
public function pickUp(event:MouseEvent):void {
if (clicked == false) {
event.target.startDrag();
clicked = true;
} else {
event.target.stopDrag();
clicked = false;
}
}
// layout the grid 9x7
public function createGrid() {
var columns:int = 9;
var rows:int = 7;
var xSpacing:int = 66.5;
var ySpacing:int = 65;
var row:Number;
var col:Number;
var num:int = (columns * rows);
var gridArray = create();
for (var i=0; i<num; i++) {
addChild(gridArray[i]);
row = (i % columns);
col = Math.floor(i / columns);
gridArray[i].x = (row * (xSpacing)+105);
gridArray[i].y = (col * (ySpacing)+118);
}
}
public static function create():Array {
var columns:int = 9;
var rows:int = 7;
var arr:Array = new Array();
var pt:MovieClip;
var num:int = (columns * rows);
for (var i:int = 0; i <num; i++) {
pt = new gridBlock();
arr.push(pt);
}
return arr;
}
}
}
1136: Incorrect Number Of Arguments. Expected 1.
I am new to Flash and Actionscript and I came across this error.
Code:
function makeDucks(event:Event) {
for (var i:int = 0; i < 5; i++) {
var number:Number = Math.round(Math.random() * (310 - 10)) + 10; //Random Position for Ducks pg27
var duckmc:MovieClip = new mcDuck();
duckmc.x = 525;
duckmc.y = number;
this.addChild(duckmc);
}
}
makeDucks();
whats the problem??
**Error** ActionScript 2.0 Class Scripts May Only Define Class........
**Error** ActionScript 2.0 class scripts may only define class or interface constructs.
b2.onPress = function() {
**Error** ActionScript 2.0 class scripts may only define class or interface constructs.
b3.onPress = function() {
**Error** ActionScript 2.0 class scripts may only define class or interface constructs.
b4.onPress = function() {
ok this is what i have.
1 Movie clip with links to a .as file all is working fine the above error occurs when i publish the 1 movie clip which is getting pulled into the main movie
Any idea's it does not happen when 1 movie clip is published on its own just when 1 move clip is pulled into my main movie clip.
[AS2 Class] Creating Extended Class Of Intrinsic
Okay,
This has been causing me a few problems lately, so I'm begging for someone to help.
I'm building an extended Date class, containing some features I use constantly in calendar, date parsing, and formatted output operations.
What's causing problems is the constructor, and passing parameters to the original Date constructor. Because the Date class allows multiple constructor formats, simply calling "super()" fails (or rather calls the Date() constructor with no parameters). I also can't pre-check and pass parameters to super() as AS requires that super be called before any other constructor code.
ANy ideas?
Creating Instances Of On Class In Another Class
Hi
I am using MX04Pro, and just starting out using external class files. i have used C++ in the past so may be expecting a bit much of AS2.
I have a class called 'channel' and one called 'Fade'
i want to create an array of Fade instances within the channel class.
ie
fadeArr[i] = new Fade(param);
i have read that i cannot use #include within a class definition, but is there a way to do what i want to?
Any help would be welcomed
Silent Bob
Instatiating Class Vs Creating Class
OK - this is a pedantic question but it has me bothered. Makes it difficult to ask questions and understand answers if I am not sure how people are using words.
When creating a instance of a class. Is "creating an instance of a class" the same as "instantiating a class"?
What I mean is - I always thought that saying
new Ship();
was "creating" the class, - the class is available but not linked to any named instance - and
var mothership:Ship = new Ship();
was "instatiating" it, as it now has the name motherShip.
?
Creating An Error Message
Let's say I have a movie clip loader called myMCL, a listener for it called myListener, and a SWF called movie.swf that will be loaded externally. I want a dynamic text box (called errorDisplay) to display an error message that says "Error: Could not access <filename>." if the movie clip loader cannot find the file. How do I refer to the file it's trying to find? Here's what I have so far:
Code:
myListener.onLoadError = function (target_mc) {
errorDisplay.text = "Error: Could not access " + <what goes here?> + ".";
}
Error When Creating Preloader....
I'm trying to create a preloader. I'm using Flash CS3 and AS3 for my website that I'm building the preloader for.
I used the basic flash preloader tutorial from this website: http://www.gotoandlearn.com/
These are the errors I got:
1120: Access of undefined property _root.var amountLoaded:Number = _root.getBytesLoaded()/_root.getBytesTotal();
1120: Access of undefined property _root.var amountLoaded:Number = _root.getBytesLoaded()/_root.getBytesTotal();
1120: Access of undefined property _root.if (_root.getBytesLoaded() == _root.getBytesTotal()) {
1120: Access of undefined property _root.if (_root.getBytesLoaded() == _root.getBytesTotal()) {
Error Creating Project: CS4
When I attempt to create a new project in Flash CS4 I consistently get the same error:
The following JavaScript error(s) occurred:
SyntaxError: missing ) after argument list
This occurs when I browse, or type in the address of the root folder for the project. I've tried this on 2 different computers and they both do the same thing (both are running Windows XP). Using Windows Vista I don't have any problems.
Any help would be greatly appreciated.
Creating An Error Message
Aloha, all! Long time Flash user, first time on the forums since Adobe acquired the property. :)
I know this is a weird request, considering we spend a lot of time asking how to get RID of an error message.
But, I'm trying to design an application where you have to sign in with your SS#. I want error messages to pop up, when the user does something wrong, like:
- When the sign in isn't 9 characters long
- When their SS# isn't found in the system...
- etc.
Any ideas on how I can make this happen? I was thinking about just doing frame jumps, but I'll need a more extensible and easily manageable solution, something we can work in with SQL over here.
Thanks in advance for all the help!
--Chad Welch
Error When Creating The KeyframeData
I was just working on the tut for sound-driven animation and when I was going through making the keyframeData.txt and after I answer the question about rounding off the values I get the following error:
Anyone know what it is and how to fix it?
It's referring to line 10 which reads
out.write(start);
I didn't know it was a problem :?:
Thanks
Error Creating Textbox With Scrollbar
I have followed a tutorial on this site to try and make a scrollable window of text and I now get an error at the point where the text should be visible on stage. Here is the error:
Symbol=window, Layer=actions, Frame=4: Line 1: ';' expected
Set Variable: "balkheight" = "200"
Could somebody please help me out here, or even better tell me an easier/better way to make a scrollable textbox. Is there a better way than this: (http://www.flashkit.com/tutorials/In...-532/index.php) to get the same/similar effect? Any better tutorials? I dont care, I just need this to work.
Error While Creating Email Link
I'm a newbie here on Flashkit and I am in need of some help desperately.
I am receiving this error when I test my movie and I am not sure what I am doing wrong. I have been trying to create links to the page using a button and so far no luck. See the error below:
-----------
**Error** Symbol=page3, layer=Layer 7, frame=1:Line 1: Mouse events are permitted only for button instances
on (release) {
Total ActionScript Errors: 1 Reported Errors: 1
-----------
How do I send my movie so that you will see what I am talking about?
Thanks for any help that you can help me with.
[F8] Error Creating Flash Movie...
I have noticed that while working on my site, if I, lets say, delete a button or swap the instance of a button; my flash file won't publish. It runs for a bit and then I get a message that says: Error creating flash movie. There was not enough memory available.
What causes this and is there any way to undo or fix this so the flash movie publishes.
[F8] Error Creating Flash Movie...
I have noticed that while working on my site, if I, lets say, delete a button or swap the instance of a button; my flash file won't publish. It runs for a bit and then I get a message that says: Error creating flash movie. There was not enough memory available.
What causes this and is there any way to undo or fix this so the flash movie publishes.
Error When Creating New Datagrid Component
I'm trying to create a new datagrid component with the instance name documents_dg. I've created the datagrid on stage but and added the folowing actionscritp code:
Code:
var documents_dg:DataGrid;
documents_dg.columnNames = ["1","2"];
but when I'm trying to test the movie I get the following error
[error]
**Error** Scene=Scene 1, layer=actions, frame=1:Line 46: The class or interface 'DataGrid' could not be loaded.
var documents_dgataGrid;
Total ActionScript Errors: 1 Reported Errors: 1
[/error]
Does anybody have a clue what is causing this error?
thnx.in.advance.marijntje
Error Creating Flash Movie...
I have noticed that while working on my site, if I, lets say, delete a button or swap the instance of a button; my flash file won't publish. It runs for a bit and then I get a message that says: Error creating flash movie. There was not enough memory available. I am using Flash 8.
What causes this and is there any way to undo or fix this so the flash movie publishes.
Flash Error-Creating .swf File
Hey, i have never had a problem with flash until now. I have made .swf's of this file heaps of times before, but for some reason, it will not make any more .swf files.
When i try to create the .swf file, i get this error... Error Creating Flash Movie. There was not enough memory available.
Please help asap! Cheers!
Error Creating Flash Movie
I have been helping a friend develop a site in flash. We've been able to edit in the FLA version and test movie to produce the SWF version with no problems. We launched the site and now have to update some things.
Again..go back and edit the FLA version no problem. All of a sudden we cant test it and create the SWF version. We keep getting this message "Error creating Flash movie. There was not enough memory available.". This has rendered us helpless as we can not produce the movie. Therefore the site can't be updated for the moment. This a huge issue.
ANY HELP WOULD BE GREATLY APPRECIATED ASAP!!!! THANKS IN ADVANCE!!!
Error Creating Flash Movie...
I have noticed that while working on my site, if I, lets say, delete a button or swap the instance of a button; my flash file won't publish. It runs for a bit and then I get a message that says: Error creating flash movie. There was not enough memory available. I am using Flash 8.
What causes this and is there any way to undo or fix this so the flash movie publishes.
Error Creating Flash Movie...
I have noticed that while working on my site, if I, lets say, delete a button or swap the instance of a button; my flash file won't publish. It runs for a bit and then I get a message that says: Error creating flash movie. There was not enough memory available.
What causes this and is there any way to undo or fix this so the flash movie publishes.
[F8] NAN Error In Class
here on key UP/DOWN i get cIndex = NaN
why?? it's used as number everywhere
please help...
instance of this is created by attachMovie
because this class is linked with movieClip symbol in library
class CViewMENU extends MovieClip{
var cIndex:Number = 0;
var keyList:Object = null;
var this_mc:MovieClip = null;
//--------------------------------------------
function CViewMENU(){
trace("CViewMENU constructor");
this_mc = this;
setActive();
}
//----------------------------------------------------------
function setActive(){
trace("CViewMENU.setActive");
keyList = new Object();
keyList.onKeyDown = fOnKeyDown;
Key.addListener(keyList);
}
//----------------------------------------------------------
function setInactive(){
trace("CViewMENU.setInactive");
Key.removeListener(keyList);
}
//----------------------------------------------------------
function fOnKeyDown(){
trace("CViewMENU.onKeyDown");
switch(Key.getCode()) {
case Key.UP :
trace("onKeyDown UP");
cIndex--;
break;
case Key.DOWN :
trace("onKeyDown DOWN");
cIndex++;
break;
}
trace("cIndex = "+ Number(cIndex));
}
//----------------------------------------------------------------------
}
NAN Error In Class
here on key UP/DOWN i get cIndex = NaN
why?? it's used as number everywhere
please help...
instance of this is created by attachMovie
because this class is linked with movieClip symbol in library
class CViewMENU extends MovieClip{
var cIndex:Number = 0;
var keyList:Object = null;
var this_mc:MovieClip = null;
//--------------------------------------------
function CViewMENU(){
trace("CViewMENU constructor");
this_mc = this;
setActive();
}
//----------------------------------------------------------
function setActive(){
trace("CViewMENU.setActive");
keyList = new Object();
keyList.onKeyDown = fOnKeyDown;
Key.addListener(keyList);
}
//----------------------------------------------------------
function setInactive(){
trace("CViewMENU.setInactive");
Key.removeListener(keyList);
}
//----------------------------------------------------------
function fOnKeyDown(){
trace("CViewMENU.onKeyDown");
switch(Key.getCode()) {
case Key.UP :
trace("onKeyDown UP");
cIndex--;
break;
case Key.DOWN :
trace("onKeyDown DOWN");
cIndex++;
break;
}
trace("cIndex = "+ Number(cIndex));
}
//----------------------------------------------------------------------
}
Class Error
Hey. I am creating a simple game for school using flash. I am trying out classes since I haven't done them in flash yet. I'm getting this error:
Code:
**Error** Scene=Scene 1, layer=Actionscript, frame=1:Line 1: Classes may only be defined in external ActionScript 2.0 class scripts.
class Player
Total ActionScript Errors: 1 Reported Errors: 1
With this code:
Code:
class Player
{
// data members
var pos_x:Number;
var pos_y:Number;
var sprite_size_x:Number;
var sprite_size_y:Number;
var nam:String;
var hp:Number;
var str:Number;
// member functions
function walk(direction:Number)
{
switch(direction)
{
// up
case 0:
{
if((pos_y - 1) >= 0)
pos_y -= 1;
else
pos_y = 0;
}
// down
case 1:
{
if((pos_y + 1) < 500)
pos_y += 1;
else
pos_y = 500;
}
// left
case 2:
{
if((pos_x - 1) >= 0)
pos_x -= 1;
else
pos_x = 0;
}
// right
case 3:
{
if((pos_x + 1) < 500)
pos_x += 1;
else
pos_x = 500;
}
}
}
}
So how and where does this "external script" go? (This code is on it's own layer in frame 1).
How To Fix This AS2 Error (class Already In Use)
Does anyone has a clue on how to fix the AS2 class error that says the name of the class is in use?
Quote:
**Error** Z:CarinhosoFLApicMotions.as: Line 4: The name of this class, 'picMotions', conflicts with the name of another class that was loaded, 'picMotions'.
{
Total ActionScript Errors: 1 Reported Errors: 1
Also, I have a code like this...
PHP Code:
var aaa:picMotion = new picMotion(img, "foto2", 5);
When I update the class with and error on porpouse it doesnt tell me anything... it keeps using the "old class build" that works and does not update it...
Flash MX2004 was all good, im having !¨%@¨%# nightmares with this problema in Flash 8, anyone else here?
AS 2.0: Class Error
Hi. This is my class definition:
Code:
import flash.xml.XMLDocument;
class mngXML {
var xmlHandle:Object;
var myXML:XML;
var count;
function mngXML() {
trace('constructor');
this.myXML = new XML();
this.myXML.ignoreWhite = true;
//this.myXML.onLoad = loadData();
}
private function loadData(loaded) {
trace('load data');
if (loaded) {
trace('ok');
this.xmlHandle = this.myXML.firstChild;
this.count = this.myXML.childNodes.length;
}
else {
trace('shhhh');
}
}
public function loadFile(filename:String,count) {
this.myXML.onLoad = loadData();
trace('load file');
this.myXML.load(filename);
}
}
in 1st frame i have:
Code:
var manager:mngXML = new mngXML();
manager.loadFile("file.xml",2);
can anybody tell me what I'm doing wrong?
Help With AS2.0 Class Error In Fl8
I have spent the better part of the day writing a script that implements the new static Zigo Engine and MosesSupposes Fuses and I get almost completely finished when I get the weirdest error suddenly:
**Error** P:Web ProjectsinProgresssectionButton.as: Type mismatch.
No line number or anything. Any Suggestions? I'll post my code if need be (and risk being harrassed to death for my inept coding skills), but I was hoping that someone else had experienced this rather obtuse error and could tell me how to fix it easily.
Oh, and btw, I've tried the ASO cache clearing thing and rebooting and it didn't help.
Thanks in advance for your support,
best wishes,
jase
Class Error
G'day
I am attempting to use Lee's reflection, read the forum pages but still can't get it to work. I put the folder com in the en/first run/classes in the c-program/flash8 folder. Did not work. syntax error.
Made sure export flash8, action script 2. Went to preferences and showed it the path. Did not work.
Then put the com folder in the same folder as the fla still did not work the last error was
**Error** C:Documents and SettingsStephenMy Documentslees_reflectioncomleebrimelowutilsReflection.as: Line 1: Syntax error.
Code:
Total ActionScript Errors: 1 Reported Errors: 1
What am I doing wrong? The lees_reflection is the folder I have the fla and com folder in.
Thaks
easy
Creating My Own Class, Or Not?
Hi everyone,
I'm working on my first actionscript test project.
I want to make a picture gallery.
So far, I can read the imagelinks from an xml file.
Also I read the description from those images from the xml file.
Then, I place a movieclip (with a picture) and a label (with the description on my movie, for all entry's in the xml file.
So far so good...
My question is:
Is it better to create my own component/class for each image?
So I can easily say where to put for example a date?
So it would be a component/class containing a movieclip and at least one label.
Or should I just build the gallery peace by peace, by just placing movieclips and labels?
What would you advice me to do?
Thanks in advance.
Help, Creating A Class From An .fla
Hi,
I've created a movie that loads a swf and has buttons to control the zooming/panning of the loaded swf. I want to create a class file to allow the reuse of these buttons. Is there an easy way to do this? Does anyone know of any good tutorials on how to do this.
I'm new to object oriented actionscripting so any help would be greatly appreaciated.
Creating Class
how to emplement this... every i load an object from xml file the object loaded will become a member of a class i called ItemStorage... anybody have ny idea... sorry just a beginer here...
Help Creating Class.
Hi!
I am creating a helloWorld example here with actionscript 3.0 but I am having some dificulties.
Here is my class :
Code:
package
{
public class Greeter
{
public function sayHello():String
{
var greeting : String;
greeting = "Say Hello!";
return greeting;
}
}
}
and here is my code at flash:
Code:
var mygreeter : Greeter = new Greeter();
mainText.text = mygreeter.sayHello();
And here are the error messages I am getting:
1180: Call to a possibly undefined method Greeter.
1046: Type was not found or was not a compile-time constant: Greeter.
What am I doing wrong?
thank you
Memory Error When Creating Projector File
Any help appreciated.
Running MX with 512MB RAM on PC, but get this message when creating projector file (for CD-rom use) with embedded video files
"Error creating Flash Movie. There was not enough memory available"
512MB isn't enough??
Could start chopping scenes and loading and unloading sub-clips, but that gets messy.
dman
Error Creating Flash Movie. There Was Not Enough Memory
"Error creating Flash Movie. There was not enough memory avaiable"
Yup.... that's the message I get when I try to publish the project I'm working on currently in Flash 6 MX.
But it must be a configuration problem cuz I just upgraded my system last fall and have tons of memory.
Azus P4P800S Motherboard
Intel 3.0 Extreme processor
1 Gig RAM
160 Gig Western Digital Hard Drive (In 3 partitions)
GeForce 5700 256Meg Video card
I have my project saved on my G drive.
It is exclusively for this project only!
The drive size is 30 Gig and only 7 Gig is used 23 Gig available
This is not a project for the web.... I'm using Flash for a business presentation of pictures, Quicktimes videos + music. I plan to take my computer with me to show the published file.
The size of my .fla file is 256 megs
I increased the size of my virtual memory from 1000mgs to 2000mgs but it didn't help
I started this project in Flash 7 MX 2004 but very early on it wouldn't publish either
So I started over in Flash 6 MX and was able to publish all along untill yesterday after I had added more video.
I have 2 weeks left before I am supposed to show this presentation and I still have about 15 - 20% more content to add.
Can anyone please help me with this?
Error Creating Flash Movie File.
Since I started using CS3 I sometimes get the following error:
Error creating Flash movie file.
Be sure the destination file is not locked or on a locked drive. Also, check that the file name is not too long.
It doesn't happen all the time, and I haven't been able to figure out what causes it. I have been able to confirm that it's not anything to do with locked files/drives, permissions, or file name length.
It happens with files created elsewhere (by other developers) that I've modified, and it happens with files I start from scratch - I can create a new FLA on my desktop and it won't publish.
Sometimes (but not always), publishing to a different directory than the one the FLA is in will work.
This is becoming a big problem. Anybody seen this, or have any ideas?
I'm on OS X 10.4.9, 2.33 GHz Core 2 Duo MacBook Pro 17", running CS3 Web Premium package.
CREATING PDF From FLASH - Error On Bitmap Colours
Hi 2 all.
I am trying to create PDF from a Flash slide presentation. All is allright but the bitmap images are converted in grayscale even if they are in RGB in the Flash stage.
The vector elements and text objects are rendered in colors. The error is only on bitmap images.
How could it be possible?
I am using Flash CS3 and I have Acrobat 7 Pro.
[wolvie]
Thanks for any support about this.
Error Creating Flash Movie File
Hey there,
I have a cartoon to send in to the network today. I'm having an issue I've had before: When I try to Test Scene, Test Movie, Publish or Export a quicktime, I get this alert: Error Creating Flash movie file. Be sure the destination file is not locked or on a locked drive. Also, check that the file name is not too long.
I've gotten this quite a few times before, and the suggested fixes don't work. Usually, I have to copy every frame and paste into a whole new project, which as you probably know, is a bitch.
Any ideas on what may be going on here? I exported a file last night before I shut down and all was well. I tried removing the audio file I added this morning to see if that was the issue, and it wasn't.
Anyone else experience this?
Thanks all!
Gordon
Error Creating Flash Movie File.
OK I have been racking my brain to get this resolved and unfortunately there isn't a lot of info on the web.
Scenario: We are in a shared environment. Central file server (Mac OS X server) over gigabit enet. We open flash files over the network and then we "try" to publish the files back to the same server in which the .fla is stored. (I have read John at Adobe's comments on the practice but this DID work).
So we access the flash file at /Volumes/ServerName/JobFolder/~Flash/ and we "attempt to" publish the .swf to
/Volumes/ServerName/JobFolder/htmlfolder/flash .... this was working previously in flash 6-7 but in 8-cs3 it has stopped working and we are kicking ourselves to get some answers.
When we try to publish we get the following error:
"Error creating Flash movie file.
Be sure the destination is not locked or on a locked drive. Also, check that the file name is not too long."
The publish path is: /Volumes/ServerName/JobFolder/~Flash/fileName.swf
What is going on and is there a solution like there USED** to be??
Class Naming Get Me An Error
hi,
i want to call my class "CompName.Components.TextFeeder",
but in my movie, when i do -
Code:
var t:TextFeeder = new TextFeeder();
i get this error -
The class 'Ts.Components.TextFeeder' needs to be defined in a file whose relative path is 'TsComponentsTextFeeder.as'.
why is that
Avi.
Weird Class Error.
I've got some code in a file called kitchenVideo.as.
The code starts as follows:code: function initialisation()
{
kitchenVideo = "kitchenVideo.flv";
...
...
There are a few insignificant lines aboe the kitchenVideo = ... line...
And there are other bits of code below.
The compiler just throws an error saying something about AS2 classes.
But... after much time and damn effort...
I've tracked down the problem to this line.
I've read Penner's book. I can't remember, but I think he mentions something about a class referencing itself or something by calling it's own name??
I've got Moock's AS2 book... just starting to read...
The problem is that even if the line kitchenVideo = ... isn't the same as the file name, it still throws an error. It's only when I call the variable a completely non related name does it stop throwing an error.
WHAT'S HAPPENING!?
Thanks.
OM
Class Error In Flash 8
I've been trying to integrate Senocular's Ease class into my SWF and when I preview the file, I get this error in the output window:
**Error** C:Documents and SettingsPhilippe DENIGERMy DocumentsProjects DriveProject FilesWork Safe For LifeflashEase.as: Line 8: Classes may only be defined in external ActionScript 2.0 class scripts.
class com.senocular.Ease {
**Error** C:Documents and SettingsPhilippe DENIGERMy DocumentsProjects DriveProject FilesWork Safe For LifeflashEase.as: Line 8: The class 'com.senocular.Ease' needs to be defined in a file whose relative path is 'comsenocularEase.as'.
class com.senocular.Ease {
Total ActionScript Errors: 2 Reported Errors: 2
Any idea what I can do to fix that?
Thanks !
Class Path Error
I'm new to AS3 and when I try to do the same package structure in AS3 as I did in AS2 it doesn't seem to work.
my swf file is in a folder called deploy.
Outside the deploy folder is another folder called source. Inside the source folder is another folder called com.
source/com
I set my claspath in the document settings like so:
file->Publish Settings->ActionScript 3.0 settings>SourcePath
I clicked the + button and added the following relative path.
../source
Inside my flash file on the first frame I try to import the class and create an instance of the class but it fails and gives me an error.
Code:
import com.TestClass;
var test:TestClass = new TestClass();
[quote]1172: Definition source.com:TestClass could not be found.
Here is my class code.
Code:
package com {
public class TestClass{
public function TestClass(){
trace("TEST WORKNG");
}
}
}
What am I doing wrong here the same structure works in AS2 but not for AS3
Actionscript 2.0 Error No Class
When I convert from Actionscript 1.0 to 2.0 I get this error message:
**Error** Symbol=room_exercise, layer=actions, frame=1:Line 1: There is no class with the name 'Number'.
var Number=0
Total ActionScript Errors: 1 Reported Errors: 1
How can I fix this?
Class Path Error
5000: The class 'todd.interactive.DisablingButton' must subclass 'flash.display.MovieClip' since it is linked to a library symbol of that type.
I have the class path correct and the all the .as file are where they should be but for some reason I get the message. Can anyone help?
Class Properties Error
I am working on my first class and so far so good. I am on the last stretch where I need to pass properties to the class. This seems simple enough but I keep getting this error
1137: Incorrect number of arguments. Expected no more than 0.
I am following the examples I have found and not sure what could be causing that.
here is my constructor code
Code:
import com.rdm.zooms.zoomerSA
var a:String = "img.jpg"
var myzoomer:zoomer = new zoomer(a);
var zmr:Sprite = new Sprite();
zmr.addChild (myzoomer)
addChild(zmr);
and here is my class
Code:
package com.rdm.zoomas
{
import flash.display.*;
import flash.events.*;
import flash.net.URLRequest;
import flash.geom.Rectangle;
public class zoomer extends Sprite {
private var _loaderHolder:Sprite = new Sprite();
var _loader:Loader = new Loader();
public var _zTogle:Boolean = false;
function zoomer (a:String) {
this.ina=a;
loadImage ("assets/images/2.jpg");
}
public function loadImage (u:String) {
_loader.contentLoaderInfo.addEventListener (Event.COMPLETE,onComplete);
var request:URLRequest = new URLRequest(u);
addChild ( _loaderHolder );
_loader.load (request);
_loaderHolder.addChild (_loader);
_loaderHolder.scaleX=.5;
_loaderHolder.scaleY=.5;
var square:Sprite = new Sprite();
square.graphics.beginFill (0xFF);
square.graphics.drawRoundRect (0, 0, 200, 200, 10, 10);
square.graphics.endFill ();
addChild (square);
_loaderHolder.mask=square;
buildBtn ();
}
function buildBtn () {
var square:Sprite = new Sprite();
square.graphics.beginFill (0xFF);
square.graphics.drawRoundRect (0, 0, 20, 20, 10, 10);
square.graphics.endFill ();
addChild (square);
square.addEventListener (MouseEvent.MOUSE_DOWN, zBtnDown);
}
private function zBtnDown (event:MouseEvent):void {
var sprite:Sprite = Sprite(event.target);
if (!_zTogle) {
_loaderHolder.addEventListener (MouseEvent.MOUSE_DOWN, mouseDown);
_loaderHolder.addEventListener (MouseEvent.MOUSE_UP, mouseReleased);
_loaderHolder.scaleX=1;
_loaderHolder.scaleY=1;
_loaderHolder.x=-100
_loaderHolder.y=-100
_zTogle=true;
} else {
_loaderHolder.removeEventListener (MouseEvent.MOUSE_DOWN, mouseDown);
_loaderHolder.removeEventListener (MouseEvent.MOUSE_UP, mouseReleased);
_loaderHolder.scaleX=.5;
_loaderHolder.scaleY=.5;
_loaderHolder.x=0
_loaderHolder.y=0
_zTogle=false;
}
}
function mouseDown (event:MouseEvent):void {
var myRectangle:Rectangle=new Rectangle(-100,-100,100,100);
_loaderHolder.startDrag (false,myRectangle);
}
function mouseReleased (event:MouseEvent):void {
_loaderHolder.stopDrag ();
trace (_loaderHolder.dropTarget.name);
}
public function onComplete (ev:Event):void {
}
}
}
as you can see I have the function in the class set up to tage arguments. and the constructor is passing them. any help would be great.
Class Import Error (?)
Hello all. I'm having problems importing multiple classes in MX 2004. I don't have the pro version.
Whenever I try to import more than one class i get the following error:
**Error** Scene=Scene 1, layer=classes, frame=1:Line 6: The class 'node.as' cannot be imported because its leaf name is already being resolved to imported class 'tabset.as'
Where tabset is the first class and node is the second. If i try to import a third, it throws the error twice.
The class appears to load and I can use it, but I want this error to go away. Anyone else run into this??
Thanks!
Document Class Error
I am working with Windows Vista Business if that makes a difference in this question.
I am testing a class file for NoScale called NoScale.as
I have created the class file attached.
I have saved the class file in the same location as the fla file.
I put in the document.class box: NoScale
Whenever I publish, I receive the following error:
5008: The name of definition 'Main' does not reflect the location of this file. Please change the definition's name inside this file, or rename the file. C:Users\%UserName%DesktopWebsiteReference FlasNoScale.as
(Note: I have replaced my username with %UserName%)
I have attempted to put C:Users\%UserName%DesktopWebsiteReference FlasNoScale.as into the document class box and I receive an error telling me that the 's are incorrect and are not allowed.
Attach Code
package {
import flash.display.MovieClip;
import flash.display.Stage;
import flash.display.StageQuality;
public class Main extends MovieClip {
public function Main() {
trace ('Main')
stage.quality = StageQuality.BEST;
stage.scaleMode = "noScale";
stage.showDefaultContextMenu = false;
stage.align = "TL";
}
}
}
|