View Single Post
  #9   Report Post  
Greg Maxey
 
Posts: n/a
Default

Dawn,

After reading your pricing scheme a little closer I don't thing I would use
a round/mod formula.


Try

{ If { = ((a1-100)/50) }{ =int((a1-100)/50) }"{
(int(((a1-100)/50)+1)*b1) }""0"}

--
Greg Maxey/Word MVP
A Peer in Peer to Peer Support

Dawn Rhoads wrote:
Hmmm... yep, rounding definitely seems to be the culprit. Do you
know what exactly the "round" feature does? A fellow here thinks he
can determine mathmatically what we need to do, regardless of how the
rounding actually works, as long he knows what the rounding will
actually do.

When I tried your IF field, I got a result of $100, when I entered a
total pages of 201, with a rate of 200. (Is that what you get, or
have I entered the calculation incorrectly?) That isn't right. What
it should be is $400. I probably haven't explained the math very
clearly. For every 50 pages over 100, there is a fee of $200. So,
0-100 pages gets $0 fee. 101-150 pages get a $200 fee. 151-200
pages gets a $400 fee. 201-250 gets a $600 fee, etc.

Thanks again for any help you can offer!

"Greg Maxey" wrote:

Dawn,

This one is not as easy as you might expect. This is due in part to
the fact that Word has no Round Up function.

I didn't have time to refine this but it will work. For the purpose
of this example, lets put Total in cell a1 and put Rate in Cell b1

The formula
{ IF a1 "100""{
=round((((a1-100)/50*b1)+(MOD(((a1-100)/50*b1),1)0)/2),0) }""0"}

should work. Note the field braces { } must be entered with CTRL+F9
--
Greg Maxey/Word MVP
A Peer in Peer to Peer Support

Dawn Rhoads wrote:
I am trying to insert an if calculation into a Word table. It will
reference two other fields in other locations in the table. One is
a number of pages (let's call that "Total"). Another is a rate
("Rate"). We think we have the math figured out, but I don't have
enough experience with IF and calculation fields to figure this out
very easily.

We also think it will use the "round" function, which we think means
if a number in our calculation is a decimal, it will be rounded up
to
the nearest whole number.

IF the Total100, then round (Total-100)/50*Rate, ELSE 0.

Any thoughts would be greatly appreciated. Thanks!