Thread: A CAP?
View Single Post
  #6   Report Post  
Posted to microsoft.public.excel.misc
M Thompson M Thompson is offline
external usenet poster
 
Posts: 37
Default A CAP?

I did a copy/paste into the cell, but it calculated everything at -400.
Thanks for spending the time on it, though.
-
OneFineDay


"Dana DeLouis" wrote:

=MIN(IF(H9="","",-MAX(0,MIN(H9,100)*0.05)+-MAX(0,(H9-100)*0.02)),400)



Would this work?

=MEDIAN(-400,-MIN(3 + 0.02* H9, 0.05* H9),0)



HTH
Dana DeLouis

= = =




M Thompson wrote:
Your answer is definitely the shortest I've seen--thus the best for me. The
only problem is for some reason it is ignoring the "if" part. It's giving a
"value" error until something is input into that cell. I got around it by
putting another if statement in front again:
=IF(H9="","",MAX(IF(H9="","",-MAX(0,MIN(H9,100)*0.05)+-MAX(0,(H9-100)*0.02)),-400)).
This works perfectly, but can I can't seem to get rid of the 2nd "if" and
still make the whole thing work. Can it be modified and still work? By the
way, as you'll notice, I mean't to say I needed a cap at -400.

Thanks for taking the time to help.