Real Data Type

Holds signed floating-point values guaranteed to be at least 64 bits (8 bytes) and provides the best performance. On Intel-based systems this is an 80-bit (10-byte) value in the range −1.18973149535723176502E+4932 to −3.64519953188247460253E−4951 for negative values and 3.64519953188247460253E−4951 to 1.18973149535723176502E+4932 for positive values.


Be aware that floating-point data types are incapable of representing many values exactly. Operations such as comparisons can produce unexpected results. See Troubleshooting Data Types for details.
ViviFire guarentees that calculations performed using the Real data type are the most optimal for a type at least as large as Double. Systems for which the most optimal floating-point type is smaller than Double are forced to use Double to maintain compatibility.
Default value
When you declare a variable of type Real and leave it uninitialized,, its value defaults to zero (0.0).
The Real data type widens to Quad without any risk of overflow.
Trailing zeros
The floating-point data types have no internal means of representing trailing 0 characters following the decimal point. This means that numbers such as 1.4200 and 1.42 represent the same value. If you must display trailing zeros, the number will need to be formatted.
Type characters
Affixing the # character to the end of a variable name declares it as having a type of Real.


Dim foo As Real
Dim bar#

See also