This is a fairly simple question, but I don't know how simple the answer may be... Or if it's even possible. I have one table with field [Quantity] that I would like to apply rounding rules to using this code or something similar:
Code:
If Me.Quantity >= 15 Then
Me.Quantity = Round(Me.Quantity,1)
Else
Me.Quantity = Round(Me.Quantity,3)
Another potential idea is this:
Code:
sSQL = "UPDATE tbl_Formulas SET tbl_Formulas.Quantity = Round(Quantity,1) WHERE tbl_Formulas.Quantity >= 15"
sSQL = "UPDATE tbl_Formulas SET tbl_Formulas.Quantity = Round(Quantity,3) WHERE tbl_Formulas.Quantity < 15"
The idea is to round numbers greater than 15 to the nearest tenth and numbers less than 15 to the nearest thousandth. I've tried toying with the field settings (double, standard, fixed, etc) but nothing works. If it isn't possible I'd still like to know. Thanks for any help.