BcdUnit
From Lazarus wiki
Jump to navigationJump to searchWelcome
Welcome to information page about FMTBcd. Goal of this page is to contain information needed for implementing FPC version of the FMTBcd.
FMTBcd unit defines a number of binary-coded decimal (BCD) routines (find the source in ..\Delphi6\Source\Vcl):
Types
TBcd = packed record Precision: Byte; SignSpecialPlaces: Byte; Fraction: packed array [0..31] of Byte; end;
pbcd will probably be a pointer to tbcd
Const
NullBcd
what is the NullBcd? is it a zero or invalid number?
Exceptions
EBcdException, EBcdOverflowException
??
EBcdException = Class(Exception); EBcdOverflowException = Class(Exception);
Utility
BcdPrecision, BcdScale, IsBcdNegative
??
Arithmetic
BcdAdd, BcdSubtract, NormalizeBcd, BcdMultiply (8 overloads)
Creation
VarFMTBcdCreate (5 overloads), VarIsFMTBcd, VarFMTBcd
Conversions
StrToBcd, TryStrToBcd, DoubleToBcd, DoubleToBcd, IntegerToBcd, VarToBcd, CurrToBCD, BcdToStr, BcdToDouble, BcdToInteger, BCDToCurr, BcdToStrF, FormatBcd, BcdCompare
Resources
only usable resource returned by google shows: http://homepages.borland.com/efg2lab/Library/Delphi/MathInfo/