Roundup Function

hillsee

Registered User.
Local time
Today, 19:50
Joined
Dec 22, 2004
Messages
18
Hiya,

I have searched the forum as u do, but i cant find a solution to my problem.

I have a form which has a 3 fields called

OvercostingCost
Estimatedcostinggreaterthan
Overcostingroundup

basically I want the field

me.Overcostingroundup = me.OvercostingCost - me.Estimatedcostinggreaterthan.

But i want the result rounded up to the nearest 1000. Can anyone help with the code please. In excel its the following code but I cant figure it out in access 2003.

=ROUNDUP(((I45-G11)/1000),0)
 
You Star !!!!

cheers mate, thanx for that, it looks so simple.

Ive been trying for half a day to do that.

thankx for the help and quick response
 
Cant get sample to round up, it jsut rounds to nearest 1000

Hiya, sorry for delay in getting back to you.

the sample doesnt round up to nearest 1000. the sample code you have given me
------------
Private Sub Command3_Click()
Me.f3 = Me.f1 - Me.f2
Me.f3 = Round(Me.f3 / 1000)
Me.f3 = Me.f3 * 1000

End Sub
-----------------
does not round up. For example if f1 = 1000 and f2 = 8450 then f3 = 2000

but if f1 = 1000 and f2 = 8550 then f3 = 1000 were what i need is for it to say 2000.

can you help???
 

Users who are viewing this thread

Back
Top Bottom