home > technical tips > access tip

access 97, 2000, 2002 (XP), 2003
excel-like rounding of numbers

question

I am used to using the ROUND function in Excel to control the number of decimal places in the results of a formula, but I cannot find one in Access. Is there one?

answer

There are a number of functions in Access that perform rounding, but none of these works in the same way as Excel's ROUND().

We have an Excel-like rounding function in VBA.

Please make use of it if you wish. It is royalty free on the understanding that you let us know of any circumstances under which it does not perform as intended.

other references

We have a technical discussion on rounding numbers and controlling decimal places in Microsoft Access and Excel.

Our description of the CDec() function appears in our technical paper on floating-point numbers.

disclaimer

DMW Consultancy Limited does not accept any liability for loss or damage to data to which any of our Technical Tips solutions are applied. Back up your data; test thoroughly before using on live data.

home database design spreadsheets website design office templates office integration IT consultancy technical tips
about dmw site map