Dear All,<br><br>hope all doing great.<br><br>I am experiencing a small problem in format function.<br><br>Basically what i am trying to do is i want to display a float value with respect to decimal places. I explain with example.<br>
<br>We have a banking application where tax calculation happens.<br><br>Now let say we have value 123.456, so when client specifies 2 decimal it shound show up<br><br>123.45.<br><br>I have tried the format function and floattostrF it dint work it shows up as 123.46 in other words it rounds up, which is very crtiical since.01 value makes huge impact in tax calculation.<br>
<br>FloatToStrF(eTemp,ffNumber,sizeof(eTemp),2)<br><br>here etemp =123.4567<br><br>I have tried this, but no luck. Anyone have any idea<br><br>Hower i know the work arround like taking the decimal position and deleting it. But it is not right way to do it i belive<br>
<br>Appreciate your help<br><br>thanks<br clear="all"><br>-- <br>  vikas<br>