• Create BookmarkCreate Bookmark
  • Create Note or TagCreate Note or Tag
  • PrintPrint
Share this Page URL
Help

Descriptions of Actions

Descriptions of Actions

Action Syntax Key Sequence Description
break break; Esc + br Breaks out of a looping statement (for, for in, do while, or while) or a switch statement.
call call (frame ); Esc + ca Performs the script attached to a specified frame label. This action is deprecated, so the action function should be used.
call function object .function (parameters ); Esc + cf Calls the function and passes the specified parameters.
case case expression: statement; Esc + ce Specifies the statements to be performed when the expression matches the switch statement.
clearInterval clearInterval(intervalID );  Stops a setInterval action from executing.
comment // comment Esc + // Allows text to be included within the Script pane for commentary only.
continue continue; Esc + co Makes Flash skip the rest of the actions within a looping statement and jump to where the condition is tested.
default default:statement ; Esc + dt Specifies the statements to be performed when none of the case expressions match the switch statement.
delete delete variable ; Esc + de Removes a variable.
do while do {

statement ;

} while (condition );
Esc + do Creates a loop that performs statements as long as the specified condition is true.
duplicateMovieClip duplicateMovieClip (target , newname , depth ); Esc + dm Creates a copy of a movie-clip instance.
else else {

statement ;

}
Esc + el Specifies the statements to be performed when the condition in an if statement is false.
else if else if (condition ) {

statement ;

}
Esc + ei Specifies the statements to be performed for an alternative condition.
#endinitclip #endinitclip Esc + ec Indicates the end of a code block for initialization. Used to develop new components.
evaluate expression ; Esc + ev Adds a new statement line in the Script pane to evaluate an expression.
for for (init ; condition ; next ) {

statement ;

}
Esc + fr Creates a loop that performs statements as long as the specified condition is true. The condition usually tests a counter that increases or decreases with each loop.
for..in for (iterator in object ) {

statement ;

}
Esc + fi Creates a loop that performs statements on the properties of an object or elements in an array.
fsCommand fscommand (command , arguments ); Esc + fs Sends commands to JavaScript in the browser environment, or to the Flash Player or Projector to control playback.
function function name

(parameters ) {

statement ;

}
Esc + fn Defines statements that perform a certain task given a set of parameters.
getURL getURL (URL , window , variables ); Esc + gu Loads the file at a specified URL (absolute Internet address or relative path) in a browser window. Provides optional arguments specifying the CGI GET or POST method.
goto gotoAndPlay (scene , frame );

gotoAndStop (scene , frame );

nextFrame();

prevFrame();

nextScene();

prevScene();
Esc + go Sends the playhead to the specified scene, frame number or frame label, and plays or stops there.
if if (condition ) {

statement ;

}
Esc + if Specifies the statements to be performed when a certain condition is true.
#include #include (path ) Esc + in Incorporates ActionScript from an external text document.
#initclip #initclip Esc + ic Indicates the start of a code block for initialization. Used to develop new components.
loadMovie loadMovieNum or loadMovie (URL , levelortarget , variables ); Esc + lm Loads an external SWF file or JPEG file into a level or into a movie clip. Provides optional arguments specifying the CGI GET or POST method.
loadVariables loadVariablesNum or loadVariables (URL , levelortarget , variables ); Esc + lv Loads variables from an external text document into a level or a movie clip. Provides optional arguments specifying the CGI GET or POST method.
method object .method =

function(parameters ) {

}
Esc + md Creates a method for an object and passes the specified parameters.
on on (buttonEvent ) {

statement ;

}
Esc + on Specifies the statements to be performed when a certain button event occurs. The on handler is always assigned to a button or a movie clip instance.
onClipEvent onClipEvent

(clipEvent ) {

statement ;

}
Esc + oc Specifies the statements to be performed when a certain clip event occurs. The onClipEvent handler is always assigned to a movie-clip instance.
play play(); Esc + pl Begins playing the movie from the current position of the playhead.
print print (location , boundingbox ); Esc + pr Prints the contents of frames.
removeMovieClip removeMovieClip (target ); Esc + rm Removes a dynamically created movie-clip instance.
return return value ; Esc + rt Returns a value calculated from a function.
setInterval setInterval(function , interval ,parameters ); or setInterval(object , method , interval , parameters );  Calls a function or a method at regular intervals.
set variable variable = value ; Esc + sv Assigns a value to a variable.
setProperty setProperty (target , property , value ); Esc + sp Assigns a value to a property of an object.
startDrag startDrag (target , centered , L , T , R , B ); Esc + dr Makes the specified movie clip follow the pointer.
stop stop(); Esc + st Stops the playhead.
stopAllSounds stopAllSounds (); Esc + ss Stops all sounds from playing.
stopDrag stopDrag(); Esc + sd Stops the movie clip from following the pointer caused by the startDrag action.
switch switch (expression ) { } Esc + sw Creates a branching conditional statement by testing whether the expression matches a case statement.
trace trace (message ); Esc + tr Displays an expression in the Output window in testing mode.
unloadMovie unloadMovieNum or unloadMovie (levelortarget ); Esc + um Removes a loaded movie from a level or a movie clip. Also removes movie clips created at runtime or author-time.
updateAfterEvent updateAfterEvent();  Updates the display independently of the frame rate when called within a clipEvent handler or within a function called from the setInterval action.
var var variable = value Esc + vr Defines local variables that are contained within a function.
while while (condition ) {

statement ;

}
Esc + wh Creates a loop that performs statements as long as the specified condition is true.
with with (object ) {

statement ;

}
Esc + wt Specifies the statements to be performed on an object or movie clip of a certain target path.



PREVIEW

                                                                          

Not a subscriber?

Start A Free Trial


  
  • Creative Edge
  • Create BookmarkCreate Bookmark
  • Create Note or TagCreate Note or Tag
  • PrintPrint