[Overview][Constants][Types][Classes][Procedures and functions][Variables][Index] Reference for unit 'sysutils' (#rtl)

BCDToInt

Convert a BCD coded integer to a normal integer.

Declaration

Source position: sysstrh.inc line 267

function BCDToInt(

  Value: Integer

):Integer;

Description

BCDToInt converts a BCD coded integer to a normal integer.

Errors

None.

See also

StrToInt

  

Convert a string to an integer value.

IntToStr

  

Convert an integer value to a decimal string.

Example

Program Example64;

{ This program demonstrates the BCDToInt function }

Uses sysutils;

Procedure Testit ( L : longint);
begin
  Writeln (L,' -> ',BCDToInt(L));
end;

Begin
  Testit(10);
  Testit(100);
  Testit(1000);
End.
The latest version of this document can be found at lazarus-ccr.sourceforge.net.