370
Chapter 12: ActionScript Dictionary
Description
Method; returns the number of milliseconds between midnight on January 1, 1970, universal
time, and the time specified in the parameters. This is a static method that is invoked through the
Date object constructor, not through a specific Date object. This method lets you create a Date
object that assumes universal time, whereas the Date constructor assumes local time.
Example
The following example creates a new
garyBirthday_date
Date object defined in universal time.
This is the universal time variation of the example used for the
new Date
constructor method:
garyBirthday_date = new Date(Date.UTC(1974, 7, 12));
default
Availability
Flash Player 6.
Usage
default:
statements
Parameters
statements
Any statements.
Returns
Nothing.
Description
Statement; defines the default case for a
switch
action. The statements execute if the
expression
parameter of the
switch
action doesn’t equal (using strict equality) any of the
expression
parameters that follow the
case
keywords for a given
switch
action.
A
switch
is not required to have a
default
case. A
default
case does not have to be last in the
list. Using a
default
action outside a
switch
action is an error and the script doesn’t compile.
Example
In the following example, the expression A does not equal the expressions B or D so the statement
following the default keyword is run and the
trace()
action is sent to the Output panel.
switch ( A ) {
case B:
C;
break;
case D:
E;
break;
default:
trace ("no specific case was encountered");
}
See also
switch
,
case
,
break
Summary of Contents for FLASH MX 2004 - ACTIONSCRIPT
Page 1: ...ActionScript Reference Guide...
Page 8: ...8 Contents...
Page 12: ......
Page 24: ...24 Chapter 1 What s New in Flash MX 2004 ActionScript...
Page 54: ...54 Chapter 2 ActionScript Basics...
Page 80: ...80 Chapter 3 Writing and Debugging Scripts...
Page 82: ......
Page 110: ...110 Chapter 5 Creating Interaction with ActionScript...
Page 112: ......
Page 120: ...120 Chapter 6 Using the Built In Classes...
Page 176: ......
Page 192: ...192 Chapter 10 Working with External Data...
Page 202: ...202 Chapter 11 Working with External Media...
Page 204: ......
Page 782: ...782 Chapter 12 ActionScript Dictionary...
Page 793: ...Other keys 793 221 222 Key Key code...
Page 794: ...794 Appendix C Keyboard Keys and Key Code Values...
Page 798: ...798 Appendix D Writing Scripts for Earlier Versions of Flash Player...
Page 806: ...806 Appendix E Object Oriented Programming with ActionScript 1...
Page 816: ...816 Index...