How can I round up a calculation? For instance:

(Total rounds /4) gives me 16.75

How do I round up the 16.75 to 17?

I've tried several FM online examples, but to no avail.

Thanks

How can I round up a calculation? For instance:

(Total rounds /4) gives me 16.75

How do I round up the 16.75 to 17?

I've tried several FM online examples, but to no avail.

Thanks

unless you want a value such as 16.25 to round to 16. In otherwords, if you want values of 16.5 to round to the next larger integer, 17 and values less than 16.5 to round to the next smaller integer (16), then you can just use the round function:

Round ( 16.75 ; 0 ) ---> 17

Round ( 16.49 ; 0 ) ---> 16

Be aware of the different situations where you want the calculation to round verses wanting a field in a layout to display rounded numbers. It could be that you want to retain the full decimal accuracy, but only display it rounded. In the inspector under the data tab at the bottom you can format number fields to be decimal so that you can set it to round to 0 for whole numbers. That way you display it rounded, but you don't change the underlying result. Just note that the layout formatting will effect how things display regardless of the value as calculated or typed, but does not change the actual number.

The basic rule for whether you round the value or round the display is "will this value be used in subsequent calculations"? Most of the time (not always), you want to keep all values unrounded until you compute the final result so you would round the display of any intermediary values if you need to show them, but use the unrounded value for additional calculations.

The common exception to the above is when the intermediary value represents currency that has to be used in a financial transaction. Then you sometimes have no choice but to round intermediary values--say it's a calculated loan payment where the customer can't make payments in fractions of a penny..., and have to take other steps to adjust for the accumulated round off error--such as adjusting the final loan payment up or down by a small amount so that the total payments exactly equals the total loan.

Hi,

you do not need a second field - you can just nest the functions. Post #1 is how I would have answered your question. Post #2 suggests then standard mathematical rounding function. Combining the two would be:

Round ( TotalRounds / 4; 0 )