ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Discussion (Misc queries) (https://www.excelbanter.com/excel-discussion-misc-queries/)
-   -   HOW DO I FORMULATE A CELL TO ROUND $5.82 TO $5.85 (https://www.excelbanter.com/excel-discussion-misc-queries/21225-how-do-i-formulate-cell-round-%245-82-%245-85-a.html)

rikg

HOW DO I FORMULATE A CELL TO ROUND $5.82 TO $5.85
 
In making price lists, I want my prices to round to the nearest .x5 or .x9 .
The cells containing the prices are from a formula in another cell.

Fredrik Wahlgren


"rikg" wrote in message
...
In making price lists, I want my prices to round to the nearest .x5 or .x9

..
The cells containing the prices are from a formula in another cell.


I'm not sure I understand what you want. I think 5.82 should be rounded to
5.8. If you want to round to the nearest 5 cent, use
=ROUND(A1*20,0)/20

/Fredrik



CLR

Assuming your price is in cell A1, put this in B1

=IF(RIGHT(TEXT(A1,"$0.00"),1)/100<=0.05,A1-RIGHT(TEXT(A1,"$0.00"),1)/100+0.0
5,A1-RIGHT(TEXT(A1,"$0.00"),1)/100+0.09)

All on one line, watch out for email word-wrap..........

Vaya con Dios,
Chuck, CABGx3




"rikg" wrote in message
...
In making price lists, I want my prices to round to the nearest .x5 or .x9

..
The cells containing the prices are from a formula in another cell.




Ron Coderre

Try this:
=TRUNC(A1*10)/10+IF((MOD($A1,0.1)+0.01)<=0.06,0.05,0.09)

Does that help?

Regards,
Ron



All times are GMT +1. The time now is 08:57 AM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
ExcelBanter.com