ActionScript 3.0 :: Movie Looping After Starting Syntax With Stop Command, No Compiler And Syntax Errors?

Jul 14, 2011

using action script...
 
stop();btn001_btn.addEventListener(MouseEvent.CLICK,showimage1);function showimage1(event:MouseEvent):void { gotoAndPlay(10);}btn002_btn.addEventListener(MouseEvent.CLICK,showimage2);function showimage2(event:MouseEvent):void { gotoAndPlay(20);}
 
however movie is playing without stopping to "Listen" for a Mouse CLICK. Images placed at frame 10 and 20 should appear only when CLICK'd.
 
This code is straight out of Classroom in a Book CS4.

View 5 Replies


Similar Posts:


Flash Movie In Cs4 - Keep Getting Syntax Errors

Oct 27, 2010

i'm trying to make a simple flash movie in cs4. scene 1 > click a button > gotoandplay scene 3 thats all.

[Code]...

View 1 Replies

Flex Builder New Projects With Syntax Errors?

Feb 19, 2010

I'm a junior developer and I'm having some problems with my flex builder 3. Every time I make a new project, flex builder detects syntax errors like:

1084: Syntax error: expecting rightbracket before leftbrace. FotoBeheer line 23
1084: Syntax error: expecting rightbracket before public. FotoBeheer line 22
1084: Syntax error: expecting rightparen before s. DomoticaSystem line 16
1093: Syntax error. DomoticaSystem line 16

Nevertheless, Fotobeheer will run, but any other program just won't even start. Does anybody have any ideas how to solve this problem?

View 1 Replies

Professional :: Syntax Errors 1093 And 1084 In Properties File

Apr 30, 2011

I'm starting to write an app, using localized strings. But I'm getting errors in a properties file, 5 errors, in lines 8 to 12, although there's only one single line in the property file. [URL].

View 2 Replies

ActionScript 2.0 :: Bracket Syntax Looping Through A Variable?

Oct 25, 2007

I'm trying to express this syntax:

Code:
container0.picture._alpha = 0;
by looping through a variable named "p", like this:

Code:
["container"+p]picture._alpha = 0;

But I get no result (and no error message).

View 8 Replies

ActionScript 2.0 :: What's The Syntax For The Size Of The Entire Movie

Sep 18, 2002

I want to move an movie clip according to the size of the entire flash movie, rather than just the movie clip. Anyone know the correct way to do this?

View 6 Replies

ActionScript 3.0 :: Access Linked Movie Clip Via DOT Syntax?

Aug 18, 2010

I have a movie clip that exists only in the library linked to a scrollpane component using its linkage identifier (the name of this MC is content_mc). It scrolls perfectly. However, in the movie clip there are additional movie clips I would like to control (green_mc), but for that I need to be able to access them using DOT syntax. How can this be done? I'm assuming that since the movie clip in the library has "export in first frame" checked that I would be able to access it somehow like this[code]...

View 1 Replies

Professional :: Change Settings And Export The Movie To A .swf - Getting A Syntax Error?

Mar 24, 2010

play ();ifFrameLoaded ("content", "loader") {    gotoAndPlay ("content", 1);}downloaded = math.floor((_root.getbytesLoaded()/_root.getbytestotal())*100) add "%";_root.bar.download_bar.gotoandstop(downloaded);bytesloaded = math.floor(_root.getbytesloaded()/1000);bytestotal = math.floor(_root.getbytestotal()/1000);_root.bar.message = bytesloaded add "Kb";_root.bar.message2 =  bytestotal  add "Kb";
 
this is for a loader on an already created flash. Which I am updating. All I am doing is changing a picture that has no coding with it, and changing the publish settings. The publish setting for the original was set for flash player 5, however I need it set to flash player 8. After I change these settings and export the movie to a .swf, I get the errors.Has the action script changed that much from flash 5 to flash 8?

View 7 Replies

ActionScript 3.0 :: Flash Syntax For Accessing An Object In Another Movie Clip?

Jul 5, 2011

I have an object named "Defer" that I need to access. That object only exists in frame 2 of a movie clip named: B2_mc. The other 4 frames of the movie clip B2_mc do not contain the "Defer" object. When I try to access "Defer" with the following code:

Defer.addEventListener(MouseEvent.CLICK, B2Redd);
function B2Redd(event:MouseEvent):void{
B2_mc.gotoAndStop(4);
}

The .swf doesn't run and the error message says I'm attempting to access an undefined property. I've never tried to access an object that wasn't on the stage, so I know my syntax is wrong for trying to access "Defer" since it's not on the stage. What's the correct syntax for drilling down to an object that may be buried deep somewhere?

View 14 Replies

ActionScript 2.0 :: Movie Clip With A Stop Command On Frame 1 And A Stop Command On Frame 20

Jul 21, 2007

I have a movie clip with a stop command on frame 1 and a stop command on frame 20.I'm trying to have two separate buttons that tell the MC (onRollOver) to play forward or to play backwards.

The actionscript on button #1-
PHP Code:
on(rollOver){    gotoAndPlay(_currentframe +1);} 
The actionscript on button #2-

[Code]...

View 1 Replies

Actionscript 3.0 :: Movie Doesn't Stop At Any Of Stop Commands And Keeps Looping Through Itself Over And Over Again

Jan 5, 2010

Im attempting to make a preloader. I am very new to action script so this is what i have.

Code:
ifFrameLoaded ( "UC" ) {
gotoAndPlay ( "home" );
}

as simple as it gets, right? Wrong, the preloader works however is get this error 1087: Syntax error: extra characters found after end of program. The preloader it self works it plays and when the movie is loaded it begins the movie, however the movie doesnt stop at any of my stop commands and keeps looping through itself over and over again till i exit the window.

View 1 Replies

AS 3 :: Syntax With Textfield?

Apr 1, 2011

I have this code gameOver1.text = (count1.currentCount / 100).toString();but i want to add some text before i display the current count. for instance in gameOver1.text i want to say

View 4 Replies

ActionScript 3.0 :: Flash - CS5.5 Compiler Errors?

Jun 2, 2011

Just upgraded from CS5 to CS5.5Code that worked in CS5 now gives compiler errors:Symbol 'VideoPlayerMC', Layer 'Layer 2', Frame 1, Line 211119: Access of possibly undefined property state through a reference with static type flash.events:VideoEvent.Symbol 'VideoPlayerMC', Layer 'Layer 2', Frame 1, Line 421119: Access of possibly undefined property PLAYHEAD_UPDATE through a reference with static type Class.

View 7 Replies

ActionScript 2.0 :: Getting A Syntax Error

Mar 15, 2009

I've just found this ActionScript and tried it out in my Flash MX file. However, when I preview the movie, it comes up with 2 errors - either for unexpected } or expected {.[code]...

View 2 Replies

ActionScript 3.0 :: Getting Syntax Error With XOR

Sep 1, 2010

Getting Syntax Error with XOR. My script is as follows[code]...

View 24 Replies

Xml :: Deleting A Particular Node Using The E4x Syntax?

May 24, 2011

I have this XML structure:

<numb>
<variable>
<name>john</name>

[code].....

View 1 Replies

ActionScript 2.0 :: Use Droptarget With Dot Syntax?

May 19, 2004

How can I replace this code to use dot syntax instead of slash?[code]...

View 1 Replies

ActionScript 2.0 :: Syntax With For Loop?

Dec 15, 2005

I've got a for loop and some fuctions working, but can't get one line of code to work. The red line below is what I'm having a hard time with. I'm calling a function called "moveit". If I insert moveit(x1, y1); then it works, and my movieclip is moved to the x and y positions that I specified for item #1. Though I want it to work for 10 items (I only have coordinates for two here, and will add the rest later).

I've searched my ActionScript book and just can't figure out what the syntax should be for calling that function.

[Code]...

View 14 Replies

Flash :: Getting CS3 AS 2.0 Syntax Error

Jun 2, 2009

I'm pretty new to Flash and my first project is my own on-line portfolio. I found (what I think is a Flash 5) code on this board to create an infinite menu. I'm trying to tweak it so that it works in AS 2.0 for CS3 and I keep getting a syntax error. [code]...

View 2 Replies

ActionScript 3.0 :: E4x Dot Syntax Not Working?

Jul 7, 2009

I think this should be pretty simple but I have been trying to figure it out for ages. I have an xmllist that i am creating from an xml object so I just get a list of nodes, I want to target each of the page nodes using square bracket syntax like this:

xml..page[0];

but for some reason it isn't working. My xml file is loaded in and is written below.I need to be able to target the nodes numerically,

xml file:
<?xml version="1.0" encode="UTF-8"?>
<root>[code].....

View 2 Replies

ActionScript 3.0 :: Explain Syntax For (X ^ (X >> 31)) - (X >> 31)?

Oct 15, 2009

explain in very very basic terms (or direct me to tutorial) what is happening in this syntax:

[code]...

this was part of and example on how to optimist code (posted in this forum awhile ago), specifically for replacing either:

[code]...

I understand how the brackets work, and that X is a variable (I presume a Number).

I assume that '^' == 'to the power of'.

I dont understand why they are using >> or 31 at all.

View 2 Replies

ActionScript 2.0 :: Using Variables In Dot Syntax?

Jun 8, 2004

This animation I'm working on has a dozen pairs of movie clips (with only two library items, one for each type in the pair) with instance names of the form "x" and "xgoal" (this is a drag and drop thing).When I'm writing AS for the "x" clip, how can I refer to its "xgoal" generally? I tried something like:goalName = this._name + "goal";And then using the goalName variable in my dot syntax (retrieving the _x coordinate for the goal clip):this.xgoal = _root.goalName._x;But, of course, that did not work. How can I get around this?

View 1 Replies

ActionScript 2.0 :: Using Droptarget With Dot Syntax?

May 19, 2004

How can I replace this code to use dot syntax instead of slash?

Code:
square.origX = _x;
square.origY = _y;

[code].....

View 1 Replies

ActionScript 3.0 :: Image Map Linking - No Compiler Errors?

Apr 9, 2009

I've made an image map in Flash using AS3, however it does not seem to be working properly. The links only work in a strange succession. In order to click all the links you must first click the last link followed by the first link, then the second link. After that the image map behaves as it is supposed to. I'm not sure why this is happening. It complies without error and aside from the little quirk mentioned above, it works beautifully. I've checked and double checked the AS, even copied and pasted some code from one button to another to see if it would make a difference, but to no avail. I am using the code listed below:

[quote] button1.addEventListener(MouseEvent.CLICK, callLink1); function callLink1 (event: MouseEvent) :void {      var url:String = ("http://www.google.com");      var request:URLRequest = new URLRequest (url);     try          {          navigateToURL (request, "_parent");         }          catch (e:Error) {             trace ("Error occurred!"); } [/quote]

View 4 Replies

Flash :: Php - Extracting SWF Gives Compiler Errors In Adobe CS4

Apr 24, 2010

I have been given an SWF to edit a link in the AS code. The fact is the SWF uses some XML that is generated (actually retrieved) by PHP code from a database. menuXML.load("/sub/page/dynamic.php?genre=" + genre); so the point is we can use the same SWF 'mainfraim' and fill them with different animations/sources based on the link provided in dynamic.php?genre=### Now, I've used Flash Decompiler Gold to extract all files in the SWF and can open it again in Adobe Flash to edit it. When done I enter CTRL+ENTER and there are immediately 4 compiler errors!! Errors:

1x < Unexpected 'if' encountered >
2x < Statement block must be terminated by '}' >
1x < Ecpected a field name after '.' operator. >

How can these errors be present, when the original SWF works perfectly??! If I don't manage to solve this, I'll have to find out how to create an .php file the SWF tries to use which can select the proper resources (from a database I guess) to show them (using ?genre=###)

View 1 Replies

ActionScript 3.0 :: Application Will Not Compile, But Gives No Compiler Errors?

May 21, 2008

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.

View 8 Replies

Actionscript 3.0 :: No Errors In Compiler - Blank Screen

Jul 4, 2011

I have been lurking here for a while. Whenever I get stuck I usually search through forums and find my answers. This ones not returning any results... So I've joined up. USING: Flash 5.0 in Windows, no flex [b] Here's my issue:[/b] I am working through Lee Brimelow's [b]Click and Zoom 3D Carousel[/b] video and I got to the first time he goes to preview his movie at about 23:50 and I get nothing. No compiler errors and no images, just a black screen...

So I figured the XML didn't go through correctly. I tried playing with the code but to no avail... If anyone could point me in the right direction that would be awesome! My tutorial document is located in the Carousel folder on my desktop, files and images are all there.

[Code]....

View 1 Replies

IDE :: Compiler Errors - Actions / Labels Layer

Feb 7, 2010

I'm getting a compiler error in my flash website the error said,
Location: Scene 1, Layer 'Actions/Labels', Frame 1, Line 12
Description: 1120: Access of undefined property furniture
Source: furniture.addEventListener(MouseEvent.CLICK,clickS action);
What is up with this error. My instance name matches in my code and in my actions/labels layer, anyone know what else it could be?

View 1 Replies

ActionScript 3.0 :: Stop A Single Movie Clip In Flash And Other Movie Clips Still Looping?

Nov 22, 2010

how to stop a single movie clip in flash and other movie clips still looping. I tried stop(); and myclipname.stop(); both are not working. I attached a simple file,

View 0 Replies

ActionScript 2.0 :: Loop Through Array Syntax?

Sep 15, 2009

I have an array like this:

Code:

var myData = new Array();
myData["name"] = "John";
myData["Age"] = 35;

What is the syntax to loop through and get the key and value? I have tried for each and for in but they just give me the value of "John" or "35", how can I get the key e.g. "Name" and "Age"?

View 2 Replies







Copyrights 2005-15 www.BigResource.com, All rights reserved