I have a macro that pulls data and performs a few additions and divisions before putting the values into Cells B4:B35. I need these to round up to the next number with no decimals. I currently have this after the data pulling/manipulation. I found this code on ehow and I cannot figure out what to put for the a1 = CDbl(InputBox("enter number you want to round"))
here is the code that I would like to happen but i am not sure if this code will even work for what I am trying to do since there is a message box that pops up and wnats me to enter a number. any suggestions would be appreciated. thanks
Dim a1, a2, s
a1 = CDbl(InputBox("B7.Value"))
a2 = CInt(InputBox("0"))
s = "=Roundup(" & a1 & "," & a2 & ")"
Range("B7").Formula = s
Range("B7").Calculate
MsgBox (Range("B7").Value)
Bookmarks