Rounding up or down in the same formula

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

How do I create a single formula to either round up or down the result of my
formula to the nearest "9"?
i.e.
843 = 839
845 = 849
etc., etc.
Thanks,
Jack
 
Are you number always integers? If so try:

=ROUND(A1,-1)-1

--
HTH

Sandy
In Perth, the ancient capital of Scotland
and the crowning place of kings

(e-mail address removed)
Replace @mailinator.com with @tiscali.co.uk
 
Try

=ROUND(A1/10,0)*10-1

problem will occur with a value smaller than 5 so you might want to use an
IF function for that or simply use

=MAX(ROUND(A1/10,0)*10-1,0)

which will return zero if a value is less than 5

--


Regards,


Peo Sjoblom
 
Doh!



--


Regards,


Peo Sjoblom


Sandy Mann said:
Are you number always integers? If so try:

=ROUND(A1,-1)-1

--
HTH

Sandy
In Perth, the ancient capital of Scotland
and the crowning place of kings

(e-mail address removed)
Replace @mailinator.com with @tiscali.co.uk
 
Thank you!

Peo Sjoblom said:
Try

=ROUND(A1/10,0)*10-1

problem will occur with a value smaller than 5 so you might want to use an
IF function for that or simply use

=MAX(ROUND(A1/10,0)*10-1,0)

which will return zero if a value is less than 5

--


Regards,


Peo Sjoblom
 
Thank you very much!

Sandy Mann said:
Are you number always integers? If so try:

=ROUND(A1,-1)-1

--
HTH

Sandy
In Perth, the ancient capital of Scotland
and the crowning place of kings

(e-mail address removed)
Replace @mailinator.com with @tiscali.co.uk
 
You might want to use Sandy's formula that will do the same with less effort


--


Regards,


Peo Sjoblom
 
Back
Top