Data.FmtBcd.DoubleToBcd

From RAD Studio API Documentation
Jump to: navigation, search

Delphi

procedure DoubleToBcd(const AValue: Double; var bcd: TBcd);
function DoubleToBcd(const AValue: Double): TBcd;

C++

extern DELPHI_PACKAGE void __fastcall DoubleToBcd(const double AValue, TBcd &bcd)/* overload */;

Properties

Type Visibility Source Unit Parent
procedure
function
public
Data.FmtBcd.pas
Data.FMTBcd.hpp
Data.FmtBcd Data.FmtBcd

Description

Converts a double precision floating point value to the corresponding binary-coded decimal (BCD) value.

Use DoubleToBcd to convert a double precision floating point value into a binary-coded decimal value. DoubleToBcd infers the number of decimal places and significant digits from the specified value aValue, using only as many as necessary. It never sets the number of significant digits to a value greater than 15.

aValue is the value to convert.

bcd returns the resulting BCD value when using the second syntax. When using the first syntax, the BCD value is the return value of the function.

See Also