http://www.csdn.net/expert/topic/532/532462.xml
或是搜一下以前的贴子,很多的。

解决方案 »

  1.   

    你用的是single,换成double,Real即可
      

  2.   

    你是用那種實數型.
    single  7-8 有效位數    4位元組
    real     11-12 有效位數  6位元組
    double   15-16 有效位數   8位元組
    comp      19-20 有效位數  8位元組
    currency   19-20 有效位數 8位元組
    extended    19-20 有效位數 10位元組
      

  3.   

    你是用那種實數型.
    single  7-8 有效位數    4位元組
    real     11-12 有效位數  6位元組
    double   15-16 有效位數   8位元組
    comp      19-20 有效位數  8位元組
    currency   19-20 有效位數 8位元組
    extended    19-20 有效位數 10位元組
      

  4.   

    用currency 是先乘以10000後, 再化為整數, 再回存時才除上10000, 便不會有誤差值.
      

  5.   

    源程序的主要部分很简单:var
     i,j,k:real;
    begin
     i:=8.5;
     j:=15.7;
     k:=i+j;
     edit1.text:=floattostr(k);
    end;edit1框中一直显示错误的结果!
    另外,我想是在edit1框中保留两位小数!
    另外,formatfloat怎么用?