This Function returns a <numeric>, which is the specified Value converted to numeric.
Parameters
Value <string> |
|
String value to be converted to numeric. |
|
|
Example 1 |
|
Example 2 |
|
Example 3 |
Val("123")
Result = 123 |
|
Val("1.23")
Result = 1.23 |
|
Val("Kalipso")
Result = 0 |
|
|
|
|
|
Example 4 |
|
Example 5 |
|
Example 6 |
Val("1minus3")
Result = 1 |
|
Val("1D3")
Result = 1000 |
|
Val("1d2")
Result = 100 |
|
|
|
|
|
Example 7 |
|
Example 8 |
|
Example 9 |
Val("1D-3")
Result = 0.001 |
|
Val("1d-2")
Result = 0.01 |
|
Val("1E3")
Result = 1000 |
|
|
|
|
|
Example 10 |
|
Example 11 |
|
Example 12 |
Val("1e2")
Result = 100 |
|
Val("1E-3")
Result = 0.001 |
|
Val("1e-2")
Result = 0.01 |
|
|
|
|
|
Example 13 |
|
|
|
|
Val("1" + "2" + "3")
Result = 123 |
|
|
|
|
- The specified Value can contain an optional plus or minus sign.
- The specified Value can contain an optional decimal-point character.
- The specified Value can contain an optional exponent part, which itself consists on an "e" or "E" character followed by an optional sign and a sequence of digits.
|
Updated: 3/22/2013 4:14 PM |