G

#### Guest

Example: 2.5 should round up to 3.

I have looked everywhere in help, there is not a RoundUp function. HELP!!!!!

You are using an out of date browser. It may not display this or other websites correctly.

You should upgrade or use an alternative browser.

You should upgrade or use an alternative browser.

G

Example: 2.5 should round up to 3.

I have looked everywhere in help, there is not a RoundUp function. HELP!!!!!

D

There's probably one available is some library somewhere,

but it's probably simpler to create a public function and

call it. Here's what I came up with, using the Round

function:

-----------------------------------------

Public Function RoundUP(RoundMe As Double)

Dim RoundAnswer As Double

RoundAnswer = Round(RoundMe, 0)

If RoundAnswer < RoundMe Then

RoundAnswer = RoundAnswer + 1

End If

RoundUP = RoundAnswer

End Function

-----------------------------------------

You should be able to call that function in a query or

whatever with the following syntax:

RoundUP(NumericVariable)

Hope that helps!

DBS (David Staas)

G

Are you saying I should customize a function? I am at in Intermediate level

with Access and am having trouble understanding the below. I am trying to

duplicate a formula I had in Excel, into Access. Excel had a RoundUp

function that I frequently used.

Please advise

Tiffani

G

module, however, I am trying to build the expression and am having trouble.

My expression in a calculated field in Query Design looks like this Total

Qty:= RoundUP(NumericVariable)[Qty Ord]*[Pck]/[MED Item Allowable]).

can you help with how I should be phrasing?

G

David THANKS! You were telling me to write a new module. I did it and it

works!!!Yeah!!!

works!!!Yeah!!!

V

-Int(-YourNumber)

For example:

?-Int(-2.5)

3

If YourNumber can be negative, chect whether you want to

use Int() or Fix().

HTH

Van T. Dinh

MVP (Access)

G

this in a query with the following:

int(NumToRoundup) +1

D

Roundup(1.0) = 1

(david)

JasDal said:

this in a query with the following:

int(NumToRoundup) +1