Round up function

S

shifty

If i have a set of number in a column is is pobbible to somehow use the
rondup function on that column with out having to put the answers into
another column?
 
G

Gary''s Student

Select the cells you would like to modify and run this one-line macro:

Sub shifty()
For Each r In Selection
r.Value = Application.WorksheetFunction.RoundUp(r.Value, 0)
Next
End Sub
 
M

Mike H

How are the numbers derived?

If they are simply values then a macro will do it but if they are formula
derived numbers then this approach could cause formulas to be lost.

Mike
 
B

Bob Phillips

=SUMPRODUCT(ROUNDUP(A1:A5,0))

--
HTH

Bob

(there's no email, no snail mail, but somewhere should be gmail in my addy)
 
Top