Rounding to left of decimal

  • Thread starter Thread starter Marc
  • Start date Start date
M

Marc

Hi,
I'm trying to round numbers in a text box in a form. (I
would like 1,265,455.63 to show as 1,265,000). I have
tried using:

=Format$(Round([TotalNames],-3))

but I get an error. If I use a positive integer or zero,
it works for that value. (=Format$(Round([TotalNames],1))
returns 1,265,455.6).

Any ideas?

Thanks,

Marc
 
Marc,

losmac is right; you must use the Val function B4
rounding. However, Round works differently in Access than
in Excel. Round's parameter merely specifies the number
of places to show beyond the decimal point. Try

=Format$(Round(Val([Number])/1000))*1000

to round to nearest thousand.

Best regards.
Kevin Sprinkel
Becker & Frondorf
 
Maybe I'm dumb, but I don't see how that helps? The
TotalNames field is already a number field.

Marc
-----Original Message-----
Try Val() function.
=Val([TotalNames])

-----Original Message-----
Hi,
I'm trying to round numbers in a text box in a form. (I
would like 1,265,455.63 to show as 1,265,000). I have
tried using:

=Format$(Round([TotalNames],-3))

but I get an error. If I use a positive integer or zero,
it works for that value. (=Format$(Round ([TotalNames],1))
returns 1,265,455.6).

Any ideas?

Thanks,

Marc
.
.
 
Thanks Kevin,

That worked! Great idea.

Marc
-----Original Message-----
Marc,

losmac is right; you must use the Val function B4
rounding. However, Round works differently in Access
than in Excel. Round's parameter merely specifies the
number of places to show beyond the decimal point. Try
=Format$(Round(Val([Number])/1000))*1000
to round to nearest thousand.

Best regards.
Kevin Sprinkel
Becker & Frondorf
Hi,
I'm trying to round numbers in a text box in a form. (I
would like 1,265,455.63 to show as 1,265,000). I have
tried using:

=Format$(Round([TotalNames],-3))

.
 
Back
Top