本文整理自网络,侵删。
要先 use System.Math; 然後?得?入的是extended,如果是double的?,小?滴?稻??有?`差// MyRound 四?挝迦?// input// amt 金?~// iprecision 小?滴??(?A?O0)// ouput// string 文字Function MyRound(amt:extended ;iPrecision:Integer=0):String;varS:String;i1:Integer;BeginS:= ”;i1:= iPrecision * -1;S:= FloatToStr(SimpleRoundTo(Amt,i1));result := s;End;
相关阅读 >>
Delphi xe的firemonkey获取当前文件所在路径的方法
Delphi Delphi tparallel cleanup needed用法
Delphi运行时的问题,cannot focus a disabled or invisible window!
更多相关阅读请进入《Delphi》频道 >>