[fpc-pascal] Extended, Currency and TDateTime memory layout

Felipe Monteiro de Carvalho felipemonteiro.carvalho at gmail.com
Sat Aug 7 23:32:24 CEST 2010


Hello,

I managed to read the extended by putting it in a program like this:

procedure TForm1.Button1Click(Sender: TObject);
var
  Hex: array[0..9] of Byte;
  Num: Extended;
begin
  Hex[0] := $00;
  Hex[1] := $00;
  Hex[2] := $00;
  Hex[3] := $00;
  Hex[4] := $00;
  Hex[5] := $00;
  Hex[6] := $00;
  Hex[7] := $80;
  Hex[8] := $FD;
  Hex[9] := $3F;
  Num := Extended(Hex);
  Caption := FloatToStr(Num);
end;

And that just confirms it, yep, the server converts the currency to extended ...

-- 
Felipe Monteiro de Carvalho



More information about the fpc-pascal mailing list