Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations SkipVought on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

How do I round a value to 1 decimal place in a function 3

Status
Not open for further replies.

Petchy

MIS
Jan 29, 2001
6
0
0
GB
I need to run a caluclation based on 1 decimal place and would like to round the value up. What's the best way to do this if at all?

Cheers,

Craig
 
If you just want to round to the nearest .x, then try:

(Int([field1]*10)/10)

If you really want to round UP to the nearest .x, then try:

IIf(Int([field1]*10)=[field1]*10,(Int([field1]*10)/10),(Int([field1]*10+1)/10))

Ron
 
Another option just crossed my mind:
iif([field1]<0;fix([field1]);-fix(-[field1]) +1)

ElGuapo
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top