TBcd stores a binary coded decimal value.
TBcd = packed record Precision: Byte; SignSpecialPlaces: Byte; Fraction: packed array [0..31] of Byte; end;
struct TBcd { Byte Precision; Byte SignSpecialPlaces; packed array [0..31] of Byte Fraction; };
TBcd represents a binary coded decimal value. It contains the following fields:
Field |
Contents |
Precision |
The number of digits in the decimal version of the value. |
SignSpecialPlaces |
The sign bit (0 is positive, any other value negative) |
Fraction |
An array of BCD nibbles, 00 to 99 per byte, high nibble first. Only the first Precision nibbles are used. |
You can create a Variant that represents a TBcd value using the VarFMTBcdCreate function. In fact, the easiest way to manipulate TBcd values is to create Variants for them and use the built-in operators provided by the Variant type.
Copyright(C) 2009 Embarcadero Technologies, Inc. All Rights Reserved.
|
What do you think about this topic? Send feedback!
|