Forum: Object-Pascal / Delphi-Language
Delphi
by DeddyH,
12. Dez 2013
Something like this?
function GetDigit(Number: Int64; Index: Byte): Byte;
var
temp: int64;
i, CountDigits: byte;
begin
temp := Number;
CountDigits := 0;
(* Retrieve total count of digits in Number *)
while temp > 0 do
Forum: Object-Pascal / Delphi-Language
Delphi
by DeddyH,
12. Dez 2013
What' s your problem exactly? You could simply use a loop and divide by 10 within it. The resulting number mod 10 should give you the value you want. If this does not work, give us a short example of the values and the expected result.