Global Functions
65
isFinite function
isFinite(expression:Object) : Boolean
Evaluates
expression
and returns
true
if it is a finite number or
false
if it is infinity or
negative infinity. The presence of infinity or negative infinity indicates a mathematical error
condition such as division by 0.
Availability:
ActionScript 1.0; Flash Player 5
Parameters
expression
:Object
- A Boolean value, variable, or other expression to be evaluated.
Returns
Boolean
- A Boolean value.
Example
The following example shows return values for
isFinite
:
isFinite(56)
// returns true
isFinite(Number.POSITIVE_INFINITY)
//returns false
isNaN function
isNaN(expression:Object) : Boolean
Evaluates the parameter and returns
true
if the value is
NaN
(not a number). This function is
useful for checking whether a mathematical expression evaluates successfully to a number.
Availability:
ActionScript 1.0; Flash Player 5
Parameters
expression
:Object
- A Boolean, variable, or other expression to be evaluated.
Returns
Boolean
- A Boolean value.
Содержание FLASH 8-ACTIONSCRIPT 2.0 LANGUAGE
Страница 1: ...ActionScript 2 0 Language Reference ...
Страница 1352: ...1352 ActionScript classes ...